In the this tutorial, I’ll show you how to sync an Inbox folder, created in earlier tutorials, between two Macs using Hazel and a folder syncing app like Dro. Sync your documents between multiple instances using Hazels built in syncing functionality. As long as both instances use a shared Sync Key, with the press of a button you can sync new documents from any other instance.
- Tatiana Hazel Sync Placements. 1 song, 1 appearance. Music by Tatiana Hazel has been featured in the The Purge soundtrack.
- Hazel's sync module and channel implementation uses libatomic. It is most likely already installed on your system, but if not, you can install it, by doing the following: MacOS: already installed Debian/Ubuntu: sudo apt install libatomic1 Fedora/CentOS/RH: sudo dnf install libatomic-static.
What is DropIt?
When you need to organize files, DropIt can eliminate much of the drudgery of searching and manually opening folders and moving files around.
Drop a group of different files and folders on the floating DropIt image and it sorts them to defined destination folders, compresses or extracts them, opens them with associated programs or performs other defined actions.
You can define how to filter your files (by name, directory, size, date, properties, content, regular expressions) and associate one of the 21 available actions to perform (Move, Copy, Compress, Extract, Rename, Delete, Split, Join, Encrypt, Decrypt, Open With, Print, Upload, Send by Mail, Create Gallery, Create List, Create Playlist, Create Shortcut, Copy to Clipboard, Change Properties and Ignore). You can also organize your associations in profiles and automatically scan monitored folders at a defined time interval to process included files.
Feature List
Drag-and-Drop
Process files and folders simply dropping them on the target imageFilter Files & Folders
By name, directory, size, dates, properties, content or regular expressionsFolder Monitoring
Process files and folders automatically monitoring defined directories21 Actions
Automatically perform an action on matching files and foldersProfiles
Collect associations in profiles and assign an image to easily recognize itComprehensive Path Support
Support absolute paths, relative paths, UNC paths for shared foldersAbbreviations
Support internal, custom and system environment variablesAlternative Usages
Support SendTo and Command-Line to process files and foldersMulti-language
Available with multi-language interfaceProfile Encryption
Support encryption to protect your profiles with a passwordAutomatic Update
Support automatic software updateActivity Log
Support log file creation to verify processing operationsUnicode
Support for Unicode encodingOptimized Versions
Available in both installer and portable versions for 32/64-bit Windows
Supported Actions
Currently DropIt allows to perform the following 21 actions on your files and folders:
- Move: to move files/folders to the defined destination folder (for example to organize images by date and properties).
- Copy: to copy files/folders to the defined destination folder.
- Compress: to compress files/folders in one of the supported destination archive formats (ZIP, 7Z, Self-Extracting EXE).
- Extract: to extract supported archives in the defined destination folder (7Z, APM, ARJ, BZIP2, CAB, CHM, CPIO, DEB, DMG, EXE, FAT, FLV, GZIP, HFS, ISO, JAR, LHA, LZH, LZMA, MBR, MSI, MSLZ, NFTS, NSIS, ONEPKG, RAR, RPM, SMZIP, SQX, SWF, TAR, UDF, VHD, WIM, XAR, XZ, Z, ZIP).
- Rename: to rename files/folders with the defined new name (using abbreviations to customize it).
- Delete: to delete files/folders with the defined method: Directly Remove (files are removed, but they could be restored using a recovery tool), Safely Erase (files are overwritten with the “DoD 3-pass” wiping method, to make them unrecoverable), Send to Recycle Bin (files are sent to recycle bin and are still available from there).
- Split: to split files/folders in parts with a defined size.
- Join: to recombine files/folders previously split (automatically trying to load missing parts).
- Encrypt: to encrypt files/folders in the defined destination folder (to protect your personal data).
- Decrypt: to decrypt files/folders in the defined destination folder (previously encrypted with DropIt).
- Open With: to open files with the defined destination program (parameters supported).
- Print: to print files using default system applications based on file formats.
- Upload: to upload files/folders to a server using FTP or SFTP protocols.
- Send by Mail: to attach files/folders to a mail and send them using SMTP protocol.
- Create Gallery: to create a image gallery in the destination folder (HTML). In particular you can create galleries with several themes like Brochure, Circles, Default, Pile, SquareHeads and many others.
- Create List: to create a list of files/folders in one of the supported destination file formats (HTML, PDF, XLS, TXT, CSV, XML). In particular you can create HTML lists with several themes like Arrowistic, Casablanca, DeepGreen, Default, Precision and many others.
- Create Playlist: to create a playlist of files in one of the supported destination file formats (M3U, M3U8, PLS, WPL).
- Create Shortcut: to create file/folders shortcuts in the destination folder.
- Copy to Clipboard: to copy the desired file information to the system Clipboard.
- Change Properties: to change file date, time and attributes.
- Ignore: to ignore files/folders and skip them during process.
How To Use DropIt?
Rules:
Set up rules to filter files and folders
Action:
Compress
Select an Action to use with matching files
Drag-and-drop files onto DropIt
Enjoy the time you just saved.
(e.g. read the Guide)
Some tutorials from the official blog: X-mouse button control. Quickbooks sierra.
Before I move on with this post, I'm going to make a couple of assumptions. I'm going to assume that you already understand that Hazel is an amazing application for macOS, that watches over folders in some form of virtual nanny-state, performing file actions on your behalf whilst you get that busy work done.
I'm also going to continue on the basis that you know about the awesome power of DEVONthink Pro Office, the Database/Paperless Office/Finder Replacement/All round swiss-army-knife-type-storage-app for macOS. Merrie melodies the crackpot quail.
They are both amazing applications and I couldn't imagine having to live without either of them. However, after reading various forums and listening to some of my favourite podcasts, it seems that the general impression is that you can't have a workflow that includes them both. Using Hazel to rename files isn't possible within DEVONthink itself.
While the statement above is largely true, a small amount of lateral thinking can, however open up some possibilities.
I'm going to walk you through the setup I have employed to allow for the renaming of files with Hazel and subsequent import into DEVONthink Pro Office.
1) All files downloaded to my Downloads folder (the default)
2) Hazel watches this folder and automatically performs OCR on any PDF files that appear, using AppleScript and PDFPen Pro
3) These files are then renamed and moved to a Holding Folder I have in Dropbox.
Hazel Sync Facebook
4) Using the built-in Folder Actions for DEVONthink, a script runs on all contents of the folder. This script will Import, OCR and Delete the original file.
Dropbox Holding Folder
The first stage is to set up a Holding Folder. Now this Holding Folder has one purpose and one purpose only. It will perform a Folder Action that will Import a file into DEVONthink, perform OCR (Optical Character Recognition, making the contents of the document searchable) and Delete the original. This folder is the final place files will reside before import into DEVONthink.
The OCR that will be completed in this stage will be using the ABBYY Fine Reader Engine, arguably the most powerful OCR software on the Mac and built-in to DEVONthink Pro Office. We're going to be performing a 'lighter' (yet still powerful) OCR at an earlier stage, so as to rename the file effectively, however the final OCR will take place here.
Why have I specified that this should be setup as a Dropbox folder? Well, firstly, any folder connected to a Cloud Service is fine (Google Drive, OneDrive, iCloud) - I just happen to use Dropbox extensively. Secondly, I find myself scanning and submitting business expense receipts from iOS a LOT. I use PDFPen Scan+ to scan the receipt, I rename with a TextExpander snippet before sending it directly to my Dropbox Holding Folder. When it reaches my Macbook, the Folder Action kicks off and the file is imported into DEVONthink.
Assigning Folder Actions
Assigning the Folder Action to your newly created Holding Folder is a simple process.
- Open Spotlight
- Search for Folder Action Setup
- Click the + button on the left hand pane. Navigate to the Holding Folder you wish to assign the action to.
- You will be presented with a list of scripts to assign. Select Devonthink - Import, OCR and Delete.scpt
Please note, you must have the scripts for DEVONthink installed. If you don't see any DEVONthink references in the box of assignable scripts, install them by clicking on DEVONthink Pro Office in the menu bar, select Install Add-Ons and tick the check box for Folder Actions Scripts.
Great stuff. You now have a folder that will act as a direct conduit between yourself and DEVONthink that is accessible from anywhere you have an Internet connection.
Hazel Rules
OK. Now, we need to set up some Hazel rules. The question we need to ask ourselves, however, is where should these rules be applied? We've set up a Holding Folder, which is going to Import, OCR and Delete thanks to the Folder Action we assigned, yet this folder needs to be the last stop for the file - the final conduit between Finder and DEVONthink. Therefore I apply the majority of my Hazel rules to the default Downloads folder. These rules will carry out some OCR (using PDFPen Pro from Smile Software and subsequently rename the file based on the results.
I'll refer to you an earlier post on Date Matching with Hazel which runs through the process of scripting the OCR, looking for a date within the contents of the document and subsequent renaming.
The only part you need to add to the rule, in order to import into DEVONthink, is to move the file into your Holding Folder once renaming/tagging etc is complete. (Remember, DEVONthink recognises Finder tags, so you can use Hazel to pre-tag your files before they hit your DEVONthink Inbox)
Hazel Sync Youtube
You can make a lot of changes to the workflow above to suit your specific needs. I know that this works for me and apart from the odd tweak here and there, I'm very happy with how it runs.
Hazel Synchrony Bank
There will be a video posted soon that walks through this process in finer detail - sometimes screencasts work better than text ever can, so watch this space and I'll let you know when it's ready!