Set default attachment folder for "same folder as the file is in"

I think all the systems have their complications.
Per folder means attachments scattered everywhere and needing a tracking method when folders are switched around - they’re not immutable.

Per vault means there will be potential problems when using nested vaults, if you add attachments while you’re in a higher level vault.

I’d just point out that, if you open your folders as vaults, then you can add attachments into an attachment folder for that vault.

1 Like

The latest insider update seems to be already fiddling with the attachments syntax for resizing of images. I’m wondering if this is an issue that can be tackled while the team is working on this? Especially with the push for Publish, seems to make sense to work on this feature.

I strongly support providing options that allow storing attachments either in the same folder as their parent note (that they were dragged to) or optionally a subdirectory of that folder. Having all attachments in one location is unmanageable for many reasons, as well as being non-portable.

2 Likes

What if the same picture is attached in two notes in the same folder, but you decide to move one of the notes to another folder, what happen whit the attach?

@henrique I think the “right” thing to do is offer to update the link in the note that moved to point to the image in the original folder.

e.g. if it was

root
 | \______ foo (dir)
 |          |____note1.md
 bar (dir)  |____note2.md
            |____img1.png 

before, in both note1 and note2, the referenced image could be as ![[img1.png]]

after moving note2.md to the bar folder, the link should be
[[../foo/img1.png]]

Another option would be a prompt that says “this note references local files that are shared by other notes. Do you want to duplicate the linked files, or update the references so they point to their original location?”

3 Likes

@luckman212 That can solve the problem.

I think it makes total sense to have more options for the folder path. But the perfect companion feature to that would be the ability to edit the filename of the embed/attachment on the spot, right there while writing in edit mode itself (and maybe inherit the name of the file with a numerical suffix as the default option).

Would something like this be possible? In fact, with that feature, I’d not care as much about not having folder options. Because even if its organized in a single Images folder then-- it’s still well-organized.

2 Likes

I have not officially changed over to Obsidian. I am still using KeepNote. This makes me wonder if I would have to go back and do a lot of cleanup if they changed it to a per folder workflow. I know if you move a note all links get updated. I am hoping attachments would work the same. I am hesitant to commit and start using it yet. I do agree that a per folder or an option as listed above is better long term.

ce

hestmatematik said:
“But the perfect companion feature to that would be the ability to edit the filename of the embed/attachment on the spot, right there while writing in edit mode itself (and maybe inherit the name of the file with a numerical suffix as the default option).”

Yes! Especially the ‘inherit the name of the file’ bit. This would be ideal.

Example: for a note called “bug in data section”

here is a line of text.
1st pasted image: auto named [[bug in data section 01.jpg]]
another line of the text
2nd pasted image: auto named [[bug in data section 02.png]]

And you can always give it a different title within your md:
[[bug in data section 01.jpg | new title]]

2 Likes

this has been implemented in 0.10.8

2 Likes

That is great news!

Not quite totally implemented, but it’s a nice progress !
As I understand it, there is still no way of naming the image subfolder after the current note.

1 Like

Open a feature request specific for that.

Woohoo, that is excellent news. Now just to find out how to become an Insider, so I can play with it.

ce

Did you ever open a feature request for making attachments relative to the path of the current note/file ?

The feature has been requested here: Support for storing attachments relative to the path of the current note/file

This feature was added in v0.10.8. Obsidian Release v0.10.8

Not yet, sorry !

Now I did : Use the current note name in the attachment subfolder name

2 Likes