Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where does Help Viewer cache files? Mac Help Viewer does not display the newest version of HTML files. This was working for weeks. What is wrong?

Xcode 4.5.2 Mountain Lion , Mac App

I follow the documentation precisely. The Help Folder and its subfolders are added to the projects /Resources folder and appears blue in color.

Folder References were added by xcode if necessary.

Whether I view the HTML file in Xcode or externally in a text editor, I see the new version of the file.

Inside the app, the Help pages all display, the anchors work, but the pages are older versions.

A particular file that is not being shown with the latest version is DgxFiles.html It is located in the scheme below as ../pgs/DgxFiles.html.

When I access Help inside the app, I see an older version of the HTML file. It seems the old help files are cached somewhere.

App's Info.plist has

<key>CFBundleHelpBookFolder</key>
<string>HungryMeHelp</string>
<key>CFBundleHelpBookName</key>
<string>com.DrummingGrouse.HungryMe.help</string>

The Landing page,HungryMe.html has:

<meta name="AppleTitle" CONTENT="com.DrummingGrouse.HungryMe.help"/>

The folder I drag into the project is named: HungryMeHelp

The Help Folder structure is:

HungryMeHelp/
    Contents/
    Info.plist
    Resources/
    shrd/ <shared artwork>
    English.lproj/
        HungryMe.html <title page>
        HungryMe.helpindex
            pgs/ <the rest of the content pages>
            sty/ <style sheets, generated list template>
            scrpt/ <scripts>

I have:

 0. Deleted /HungryMeHelp and re-added it.
 1. Cleaned the project.
 2. Reloaded Xcode
 3. Rebooted Mac

Trash the following files in your Home > Library > Preferences folder

com.apple.help.plist
com.apple.helpui.plist
com.apple.helpviewer.plist

Trash the following folders in your Home > Library > Caches folder

com.apple.helpui folder
com.apple.helpdata
com.apple.helpd
com.apple.helpviewer

What am I missing?

Thanks for reading. Mark

like image 366
mbarron Avatar asked Nov 24 '12 15:11

mbarron


1 Answers

I found answers to my Apple Help Viewer Cache questions here:

http://www.cocoabuilder.com/archive/cocoa/312037-updating-an-app-help.html http://macergun.blogspot.com/2011/06/dealing-with-help-viewer-cache.html

I found the posting below at cocoabuilder.com As a result, I deleted existing copies of the app from my system. The Help System updated immediately thereafter!


On Dec 13, 2011, at 5:17 PM, Graham Cox wrote:

With each update of our app, we typically change the help book. We're finding that the system is very poor at recognising this and caches old versions of the help which causes new stuff we add to be unavailable. While I can manually trash the help caches and force an update, this isn't something we can ask or expect of our users.

Search the archives, and you will discover that you are likely experiencing a well-known issue that has been around for a very long time. It typically only affects the developer, not your users. It is especially annoying to the developer if another, older version of the application is still on your computer, in the Applications folder or perhaps in the form of earlier build products that are still sitting around, because then trashing the help caches and forcing an update won't necessarily stop the system from using the old version of your Help folder in an older version of your application.

When I am working on my Help folders, I routinely compress all older versions of the application into zip files for the duration, and I trash the Help caches before every test.

The typical user trashes the old version of the application when they install the new version, and all is well.

--

Bill Cheeseman -

like image 108
mbarron Avatar answered Oct 08 '22 05:10

mbarron