Use case or problem
Obsidian allows you to set an attachment folder as a sub-folder of the current file. However, these folders are not auto-created and you cannot name them with a dot (.) as the first character, such as “.media”
The workflow right now is:
- manually create the folder name such that it matches the name set in the files settings
- drag a file into the editor
If you don’t manually create the attachments dir under the file you’re editing, the attachment lands in the same folder as the document. If you have the folder name set to something that starts with a dot, then you can’t attach files at all, it just silently fails.
The workflow should be:
- drag a file into the editor
- Obsidian creates the attachment folder if it doesn’t exist and places the file there
Proposed solution
Keep the existing settings, but when you drag a file into the editor, create the attachments directory if it doesn’t already exist.
Current workaround (optional)
Manual steps listed above. If you mis-spell the folder you manually created nothing will land there.