Advanced Preferences

The following preferences are available in Hookmark’s Advanced Preferences tab:

Prevent Hookmark from searching specified locations

With Hookmark’s Advanced preferences tab (available to Hookmark Pro users), you can specify which folders Hookmark should ignore when it tries to resolve hook://file/ links. This is analogous to Spotlight’s privacy pane in System preferences. However, this is not a privacy function but a convenience, as explained below.

Hook-6.4-Prefs-advanced.png

This pane has a single editable list of folders labeled “Prevent Hookmark from searching these locations:” with this explanation below: “Finder folders listed on the right will be ignored when Hookmark tries to resolve file links (hook://file/)”. This applies to the “first” time Hookmark resolves such a link (as explained below).

In the image above, you’ll see that we have configured Hookmark to ignore files and folders in the /Users/lucb/restore-Exclude FROM SPOTLIGHT folder.

When to edit the “ignore” list

First, some background

When you copy a link to a file, Hookmark creates a hook://file/ bookmark that points to the file; and Hookmark begins to track this file. For this purpose, it stores the original file’s location (“pathname”) and other meta-data in its database. As you move the file around, or rename it, Hookmark updates its information about the file. That enables links to this file (“bookmarks” and “hooks”) to keep working when you:

  • use Hookmark on different Macs (assuming you enable Hookmark’s syncing across Macs);
  • remount volumes (disk images, removable storage);
  • checkout repositories in version control systems (like Git and Subversion); or
  • sync cloud shared folders locally on your Finder (e.g., from Dropbox and Sync).

When you paste a literal hook://file/ link for sending to others (or to yourself on different Macs), you may notice that Hookmark codes information about the file in the link’s URL. Only the current filename (not the path) is explicitly legible (unencrypted). For instance, this is a link to an Application Support folder. Its URL is hook://file/EqVgyQJJb?p=bHVjYi9MaWJyYXJ5&n=Application%20Support. If you try opening that link with Hookmark on a typical Mac, it’s likely to open in your ~/Library/Application Support folder.

When you click on such (hook://file/) links received from others, Hookmark has no prior information about the target. It must rely only on the URL. Internally, Hookmark then triggers a search for the file. It looks for files with the same name and similar paths.

As alluded to in the list above, Hookmark also needs to resolve hook://file/ links when you import bookmarks or sync bookmarks between Macs. In other words, when your local instance of Hookmark effectively encounters a given link for the first time (or “as if for the first time”).

However, you might have a backup folder on your Mac with copies of files you’ve linked to. When Hookmark initially resolves a link, you typically don’t want those links to point to duplicates of your files (such as backups). You’ll want them to point to the originals. How is Hookmark supposed to know what folders contain lots of files that are irrelevant to your linking needs?

Solution

The solution is simple! Before you import or resolve links, configure the list of folders specified in the Advanced preferences pane, next to Prevent Hookmark from searching these locations:.

“What if I forgot to configure the list of folders to ignore?”

Suppose you forget to configure this setting before resolving links for the first time, and some of your links now point to resources in the “wrong” folder. It is easy to recover.

  1. Configure the list of folders to ignore.
  2. Export your bookmarks, following these instructions.
  3. Re-import your bookmarks, following the instructions on the same page.

What this “ignore” list does not do

The “ignore” list will not prevent Hookmark from honoring links that it has already resolved that you’ve already created that point to a folder in the “ignored” list. Also, you can override this setting by deliberately selecting a file in that folder and linking to it (e.g., with Copy Link, Copy Markdown Link, Hook to Copied Link, or using the menu bar icon’s linking widgets).

Also, it does not fully prevent the possibility of some shared hook://file/ URLs pointing to the “wrong” file. It could happen that two files in searched folders are very similar and Hookmark has no way of knowing which this link points to. So when you click on a hook://file/ link, you should keep that in mind. (Hookmark’s General Preferences contains an option to reveal files in Finder which applies to hook://file/ links stored outside Hookmark.) You can delete bookmarks, hooks and literal links.

Show Dock checkbox, meaning run in foreground or backround mode

The show Dock setting determines whether Hookmark’s Dock is visible or not. If the Dock icon is visible, then Hookmark runs in foreground mode. If the Dock icon is not visible, then Hookmark runs in background mode.

When you choose to hide the Dock, you will get a dialog box that asks you to confirm your choice, saying:

In order to run Hookmark without a Dock icon, it has to run as a “background application”.
Running Hookmark in background mode has the following implications.

  1. Hookmark’s menubar will not appear even when Bookmarks window is shown.
  2. Because of the missing menu bar, the Hide Others command (⌥⌘-H) will not work while Hookmark is active.
  3. Hookmark will not appear in the Application Switcher (⌘Tab).
  4. Hookmark will not appear in Apple Menu’s “Force Quit” list of apps, even while it is running.
  5. the “Hide Others” command (⌥⌘ H) will not list Hookmark, even while it is running.
  6. As noted, you will not see Hookmark in the Dock.

Note that even in foreground mode, Hookmark’s context window does not have its own menubar.

Questions?

Just get in touch.