├── .github
└── FUNDING.yml
├── README.md
└── assets
├── devonthink_icon.png
└── previews
├── dvn-buffer1.png
├── dvn-buffer2-universal-action1.png
├── dvn-buffer3-universal-action2.png
├── dvn-config.png
├── dvn-db-search.png
├── dvn-dbs1.png
├── dvn-entry.png
├── dvn-hotkey-dt3-selection.png
├── dvn-import.png
├── dvn-instances.png
├── dvn-record-action1.png
├── dvn-record-action2.png
└── dvn-tagsearch.png
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | ko_fi: zeitlings
2 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |
2 |
3 | DEVONthink 4 Portal
4 |
5 |
6 |
7 |
8 |
9 | ---
10 |
11 | Advanced DEVONthink 4 interface for your databases
12 |
13 | ## Usage
14 |
15 | __Search your databases__ via the `dvn` keyword, using any [prefix](https://download.devontechnologies.com/download/devonthink/3.8.2/DEVONthink.help/Contents/Resources/pgs/appendix-searchprefixes.html), wildcard, or [operator](https://download.devontechnologies.com/download/devonthink/3.8.2/DEVONthink.help/Contents/Resources/pgs/appendix-operators.html) also available in DEVONthink.
16 |
17 | Use the [Universal Action](https://www.alfredapp.com/help/features/universal-actions/) to __import documents__ to a specific location.
18 | To either jump to the global __group search__, or the active __document winows__, use the `dvng` or `dvna` convenience keywords.
19 | Set up the [Hotkey Trigger](https://www.alfredapp.com/help/workflows/triggers/hotkey/) to act on your __current selection__ in DEVONthink.
20 | Alternatively, use the `ddvn` keyword for a fast brute force query over your documents.
21 |
22 | ### Usage Details
23 |
24 | `dvn [⎵] [ . ] [ query ]`
25 |
26 | - `dvn ` Show all databases.
27 | - `dvn .` Show globally available actions.
28 | - `dvn query` Search globally in all databases.
29 | - `dvn ?` Show internal configuration.
30 |
31 |
32 |
33 | ## Feature Overview (Selection)
34 |
35 | - Global and Database Search
36 | - ~~Tag Search with Auto Suggest~~
37 | - Document actions
38 | - move, replicate, duplicate, create annotation file, find similar items, etc.
39 | - >`Extra` Get the BibTeX reference or CSL formatted citation from a DOI, ISBN or jstore URL.
40 | > CSL formatted citations can also be generated from an existing BibTeX reference.[^1]
41 | - Multiple document actions
42 | - move, replicate, open all, **reciprocal linking**, etc.
43 | - > __Note__[^2]
44 | - Navigate the folder structure
45 | - Import new documents to location
46 | - Customizable annotation templates
47 | - Colored labels (customize as needed)
48 | - Colored flags on labeled records
49 | - Copy page link for open pdf documents
50 |
51 |
52 | ## Actionable Options
53 |
54 | **Global Options** Trigger: ` dvn . `
55 |
56 | - Find Groups
57 | - Show Favorites
58 | - Show Reading List
59 | - Today
60 | - Recently Modified
61 | - Recently Added
62 | - Recently Opened
63 | - Due Soon
64 | - Overdue
65 | - Filter Smart Groups
66 | - Load Workspace
67 | - Save Workspace
68 | - Delete Workspace
69 | - Find Records similar to a given String
70 | - Affected by the `Score Threshold` configuration variable
71 |
72 | **Database Options** Trigger: ` dvn |dbs|2| . `
73 |
74 | - Find Groups in Database
75 | - Access Default Groups & Filters
76 | - Inbox
77 | - Annotations
78 | - Trash
79 | - Tags (autocompletes to tag search)
80 | - Today
81 | - Recently Modified
82 | - Recently Added
83 | - Due Soon
84 | - Overdue
85 | ---
86 |
87 | ## Search
88 |
89 | ### Default Search
90 |
91 | The search behaves the same as in DEVONthink, but by default only returns documents, i.e. groups, smart groups and tag groups are ignored. The workflow respects DEVONthink prefixes, operators and wildcards, giving you full control over the query. Examples:
92 | - `name:~keyword`
93 | - `name:
98 |
99 | > __Note__
100 | > Within the database root or any folder, typing an asterisk `*` will return the entire contents of that location.
101 |
102 | Reference for [__Search Prefixes__](https://download.devontechnologies.com/download/devonthink/3.8.2/DEVONthink.help/Contents/Resources/pgs/appendix-searchprefixes.html).
103 | Reference for [__Search Operators__](https://download.devontechnologies.com/download/devonthink/3.8.2/DEVONthink.help/Contents/Resources/pgs/appendix-operators.html).
104 |
105 | ### Tag Search
106 |
107 | > Currently unavailable in Dt4Portal v2.0.0
108 |
109 | Queries can be refined with tags at any point. Type the octothorp symbol and start entering the name of the desired tag. The workflow will auto suggest tags from your DEVONthink databases.
110 |
111 | Tags come in three flavors:
112 | - `#tag` defines a strict requirement (show only documents that have this tag)
113 | - `#tag?` defines an optional requirement (show documents that either have this tag, or another optional tag)
114 | - `#!tag` defines a tag that is to be excluded (do not show documents that have this tag)
115 |
116 | **Autocomplete Modifiers**
117 |
118 | Tag suggestions can be autocompleted to match the above mentioned flavors.
119 | - `default` the document must have this tag (`#tag`)
120 | - `cmd` __⌘__ the document must not have this tag (`#!tag`)
121 | - `opt` __⌥__ the document may have this tag (`#tag?`)
122 |
123 |
124 |
125 | Expand for preview
126 |
127 |
128 |
129 |
130 |
131 | ## Entry Point and Search Results
132 |
133 |
134 |
135 | - `default` Enter Database Search
136 | - `cmd` __⌘__ List all Tags in Database
137 | - `opt` __⌥__ Open Database in DEVONthink
138 |
139 |
140 |
141 | - __⌘1__ `⏎` return key steps into the parent group
142 | - __⌘2__ `⏎` return key steps into the targeted group
143 |
144 |
145 | ### Search Results
146 |
147 |
148 |
149 | Press the `⏎` return key to access the [actions](#record-actions) available for the record.
150 |
151 | | Modifier | Action | Configuration |
152 | |---: |:-- |:---: |
153 | | `cmd` | Display Tags | |
154 | | `opt` | Open in DEVONthink or Default Application | ⦿ |
155 | | `ctrl` | Reveal in DEVONthink | |
156 | | `shift` or `cmd+Y` | Quick Look Preview | |
157 | | `cmd+L` | Large Type showing the File Name, Location and Tags | |
158 | | `fn` | View the score of the record (responds to the configured *threshold*) | ⦿ |
159 |
160 | > __Note__
161 | > Press the `⏎` return key while the workflow is retrieving the search results to launch DEVONthink with the given query.
162 |
163 | ## Record Actions
164 |
165 | |
|
166 | |:--:|
167 | | Record Actions - A |
168 |
169 | ### ` ⌘2 ` The Main Record
170 |
171 | Press the `⏎` return key to open the record in DEVONthink or the default application for the file type (Configuration).
172 |
173 | | Modifier | Action | Configuration |
174 | |---: |:--- |:---: |
175 | | `cmd` | Open in default application or in DEVONthink | ⦿ |
176 | | `cmd+c` | Copy item link or page link if the record is open in a DEVONthink document window | ⦿ |
177 | | `cmd+shift` | Copy Markdown Link | |
178 | | `opt+shift` | Copy page link (unless set as default) | ⦿ |
179 | | `opt` | Reveal in DEVONthink | |
180 |
181 | ### ` ⌘5 ` Move Record
182 |
183 | Press the `⏎` return key to select a new location for the record. If the record has replicants, you will have to decide which instance to move on a subsequent view (Configuration).
184 |
185 | ### ` ⌘8 ` Instances (Configuration)
186 |
187 | Press the `⏎` return key to explore the instances, that is, replicants and duplicates of the record.
188 |
189 |
190 | Expand to preview
191 |
192 |
193 |
194 |
195 |
196 | ### ` ⌘9 ` Create an Annotation File for the Record
197 |
198 | If an annotion file already exists for the record, that file is displayed instead.
199 |
200 | > __Note__ See [`Annotation Templates`](#annotation-templates)
201 |
202 | ---
203 |
204 | |
|
205 | |:--:|
206 | | Record Actions - B |
207 |
208 | ### ` ⌘2 ⌘3 ` DOI and ISBN
209 |
210 | | Modifier | Action | Configuration |
211 | |---: |:--- |:---: |
212 | | `cmd` | Get the BibTeX reference or CSL formatted citation via the *µBib Workflow* | ⦿ |
213 | | `cmd+c` | Copy to clipboard | |
214 |
215 | ### ` ⌘4 ` BibTeX
216 |
217 | | Modifier | Action | Configuration |
218 | |---: |:--- |:---: |
219 | | `cmd` | Get CSL formatted citation via the *µBib Workflow* | ⦿ |
220 | | `cmd+c` | Copy to clipboard | |
221 |
222 | ### ` ⌘7 ⌘8 ` Incoming and Outgoing Links
223 |
224 | View incoming or outgoing (wiki) links or mentions.
225 | > __Note__
226 | > *Linking records* together injects references into the custom metadata of the records, which are registered by DEVONthink as inbound or outbound links. See [`On Reciprocal Linking`](#on-reciprocal-linking)
227 |
228 |
229 |
230 | ## Hotkey and Universal Action
231 |
232 | You can send your selection to the `dvn Universal Action` from either the file system or from within DEVONthink. To act on the records currently selected in DEVONthink, you can also use the hotkey `cmd+shift+D` by default.
233 |
234 |
235 |
236 |
237 | The most recently used import location is remembered for quick access. The number of remembered import locations can be defined in the Wokflow Configuration.
238 |
239 |
240 | ### Buffered Records
241 |
242 | You can push records to Alfreds file buffer to perform actions on all of them, such as moving, replicating, or linking them together.
243 |
244 |
245 |
246 | Send all buffered items to the Universal Action interface with ⌥+▶
247 |
248 |
249 |
250 |
251 |
252 |
253 | ## On Reciprocal Linking
254 |
255 |
256 | > __Warning__
257 | > Potentially replaces preconfigured data if the custom metadata identifier `mdlinkedrecords` is already in use. Change this value in the configuration to avoid conflicts if necessary.
258 |
259 |
267 |
268 |
269 | ## Custom Metadata
270 |
271 | The workflow responds to the following DEVONthink custom metadata identifiers:
272 |
273 | - `mddoi`: DOI
274 | - `mdisbn`: ISBN
275 | - `mdlink`: Link
276 | - `mdlinkedrecords`: Linked Records (Configuration[^2])
277 |
278 |
279 | ## Annotation Templates
280 |
281 | You can create custom templates that will be used when creating an *annotation file* for some record, i.e. a markdown document that is associated with it. You can customize your templates in `/assets/annotations`. These `placeholder` variables are currently supported:
282 | - `%recordName%`
283 | - `%documentLink%`
284 | - `%year%`
285 | - `%month%`
286 | - `%day%`
287 | - `%hour%`
288 | - `%minute%`
289 |
290 |
291 | ## Plugins
292 |
293 | - [**µBib**](https://www.github.com/zeitlings/ubib/) | *Citations, BibTeX, and Research*
294 | - **PDF Expert** Copy the DEVONthink page link for the page currently viewed in PDF Expert
295 |
296 |
297 | ## Configuration
298 |
299 |
300 |
301 | Some internal configuration options are available via `dvn ?`
302 | - Open Workflow Configuration
303 | - Browse Annotation Templates
304 | - Browse Workflow Cache
305 | - Browse Workflow Data
306 | - Show Documentation
307 | - Clear Cache
308 |
309 | ### Labels
310 |
311 | Currently it is not possible to extract the names you have assigned to your labels directly from DEVONthink. However, you can enter them into the text field where they are picked up by the workflow.
312 |
313 | The colored icons for the labels are located in `./icons/labels` and `./icons/labels_flagged`. If you want different colored icons, you have to replace the existing icons with new ones.
314 |
315 |
316 | ---
317 |
318 | # Notes
319 |
320 | - Supports DEVONthink 3.8.7 or later. Version 3.8.7 brought breaking changes to the scripting bridge.
321 | - `Tip` Fine-tuning the threshold becomes more interesting the larger your database grows. High thresholds for small databases can be detrimental to accuracy.
322 |
323 |
324 |
325 |
326 | [^1]: Optional. Requires the `µBib` Workflow to be installed. DEVONthink will try to automatically extract DOIs from documents. However, this does not always succeed. You can help DEVONthink out by adding a custom metadata field with the identifier `DOI`. [µBib on Github](https://www.github.com/zeitlings/ubib/).
327 |
328 | [^2]: Attention! Potentially replaces preconfigured data if the custom metadata identifier for *Linked Records* (`mdlinkedrecords`) is already in use. Change this value in the configuration to avoid conflicts if necessary.
329 |
--------------------------------------------------------------------------------
/assets/devonthink_icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/devonthink_icon.png
--------------------------------------------------------------------------------
/assets/previews/dvn-buffer1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-buffer1.png
--------------------------------------------------------------------------------
/assets/previews/dvn-buffer2-universal-action1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-buffer2-universal-action1.png
--------------------------------------------------------------------------------
/assets/previews/dvn-buffer3-universal-action2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-buffer3-universal-action2.png
--------------------------------------------------------------------------------
/assets/previews/dvn-config.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-config.png
--------------------------------------------------------------------------------
/assets/previews/dvn-db-search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-db-search.png
--------------------------------------------------------------------------------
/assets/previews/dvn-dbs1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-dbs1.png
--------------------------------------------------------------------------------
/assets/previews/dvn-entry.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-entry.png
--------------------------------------------------------------------------------
/assets/previews/dvn-hotkey-dt3-selection.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-hotkey-dt3-selection.png
--------------------------------------------------------------------------------
/assets/previews/dvn-import.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-import.png
--------------------------------------------------------------------------------
/assets/previews/dvn-instances.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-instances.png
--------------------------------------------------------------------------------
/assets/previews/dvn-record-action1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-record-action1.png
--------------------------------------------------------------------------------
/assets/previews/dvn-record-action2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-record-action2.png
--------------------------------------------------------------------------------
/assets/previews/dvn-tagsearch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zeitlings/alfred-devonthink/be75cb7e8152b4ea74e98f7354de847d75df75e8/assets/previews/dvn-tagsearch.png
--------------------------------------------------------------------------------