glushchenko / fsnotes

Notes manager for macOS/iOS

Home Page:https://fsnot.es

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Open attachments by links

geshaowen opened this issue · comments

When using FSNotes, I need to associate local files, such as PDF, Word, Excel, etc. Currently, after adding a link, I cannot directly open the file. I hope to add a feature where clicking on the link can directly open the corresponding attachment.

Assuming macOS. It's possible with a bit of extra knowledge.

You can do this in Markdown, note there are 3 slashes after file: the third of those is part of the path.

[PDF](file:///Users/yourname/Documents/folder/file.pdf)

You can the file path by copying the file in Finder and then pasting into FSNotes will paste the file path.

  • You can click the link and it will show the file in Finder

Then you will still need to open the file manually (Cmd+O, or Cmd+Down cursor)

  • If you right click and choose "Open in Preview" (or whatever app) it will not open

error: The application “FSNotes” does not have permission to open “file.pdf”.

SO:

Then you can right click the link, choose Services > Open and the file will open in its default app (you can change the default app per-file or globally using the Get Info window on a file of a particular type).

You can also set a hotkey for this Service through System Settings > Keyboard > Keyboard Shortcuts... > Services > Text > Open, but I'm not sure it would make things much easier as you would still need to right click the link before pressing the key.