Tinderbox can automatically import selected notes from the any Finder folder, including folders in Dropbox or other remote servers. This is set up via the File menu.
Multiple watched folders are supported, i.e. more than one (root level) watched Finder folder.
To connect Tinderbox to a folder, create a root level container (and it can only be at root level) to hold the imported notes and set its $WatchFolder attribute to the name of the Finder folder you want to import. The watched file may be only local to the host Mac drives or may be a shared file via iCloud or Dropbox. Tinderbox will automatically import to or update that container (for supported format files) whenever the TBX document is reopened, and periodically thereafter as part of the AutoFetch cycle.
The new container created in Tinderbox uses the same name as the source OS folder in Finder and as, as a Displayed Attribute, $WatchFolder. The latter\s value is the POSix local path to the watched folder. Reseting the $WatchFolder to the default (i.e. no value) will cause the Watch function to cease operating.
The imported notes inherit from a built-in prototype named 'Imported From Finder', making it easy to common Displayed Attributes or visual appearance. Finder tags are imported into $Tags.
New items
On detecting a new source file, Tinderbox will add a note with the complete source filename (including extension) with the above prototype auto-assigned. The new notes Displayed Attributes table shows (via the prototype):
- File holds the OS path of the source file.
- $NotesModified shows when the item was first added.
- $LastFetched shows when the source note was last detected as changed (as opposed to when the resource was last checked).
- $ReadOnly, though this can be toggled off by the user.
- $Tags, any imported Finder tags.
If the user chooses, additional Displayed Attributes can b e added via the prototype (or individual note's $DisplayedAttributes) though such displayed attributes cannot be editing in the Displayed Attributes table whilst $ReadOnly is ticked (true
).
Changed Items
When, during autofetch, a source note is detected as changed (i.e. as a different macOS modification date/time) the affected note is updated:
- the $Text value is replaced by the current source text.
- the $Tags value is replaced by the current source finder tags.
- $LastFetched is updated to the time of this (Tinderbox) edit (not the source file's OS modified date/time).
- if a source file is now missing (e.g. deleted or moved) Tinderbox retains the note, but the user may delete it without the note being later regenerated.
Note that the 'update' overwrites existing $Text and $Tags. In the case of $Tags the inputs are not merged so any tags set in Tinderbox would be lost. Apart from the 3 attributes above, no other change occurs so things like user attributes set for the note will not be affected.
Limitations:
- Changes to the imported notes will not be propagated back to the source application (i.e. Finder) or to other devices: the source data is watched, not two-way synchronised.
- Notes created by watching Finder are read-only by default, inheriting $ReadOnly from their prototype.
- Changing Finder tags, e.g. via File Info, does not necessarily trigger a change to the file's OS modified date/time so Tinderbox does not detect a change. Therefore it may be necessary to alter the files OS modification date/time by other means if it is desired that Tinderbox detects a change only to tag data.
- there is no way to know when the AutoFetch last ran, though the Tinderbox Inspector's Agents & Rules tab gives some idea (the circular progress meter). As no change happens if no change is detected as source, the only way to be sure the watch has run, e.g. if an expected source change does not appear in Tinderbox, is to close both the TBX and the Tinderbox app, then re-open both. Note the point above that simple changes to (Finder) tags in Finder File Info does not mark the file as changed.
Factors to consider when using watched Finder folders
If intending to use menu File ▸ Watch ▸ Folder from Finder, be aware the target folder may contain a mix of documents some of which Tinderbox cannot read/view (i.e. make meaningful use of).
If this is the case consider separating non-compatible