RainCat1998 / obsidian-custom-attachment-location

Customize attachment location with variables($filename, $data, etc) like typora.
MIT License
237 stars 36 forks source link

[FEATURE REQUEST] Excluding based on context (pasted vs relative path link image, regex) #103

Open cybersader opened 2 months ago

cybersader commented 2 months ago

What would be useful is to be able to:

  1. Exclude files or folders like with the attachment management plugin, and it would be even better if we could have regex to exclude certain extensions, folders, or files, etc.
  2. Exclude cases where I dragged and dropped an image that's already in the vault (relative path to an existing image in the vault). It would be awesome if this setting could be overridden for certain folders as well just as with the above regex-based exclusions.

Organizing images that I've pasted from my clipboard into the vault is very useful, because it makes for an organized home for attachments. However, I shouldn't care about other cases such as the ".svg" image that I have generated from my Excalidraw diagrams. Setting #2 would mean that I can drag and drop this image into a note (using relative path essentially) without disconnecting the .svg from the Excalidraw plugin.

The prime issue here with Excalidraw + Custom Attachment Location - Excalidraw auto-updates the .svg when the diagram is changed, but this won't update in the notes that the .svg is a part of because Custom Attachment Location force changes the name.

Let me know if you need more context.

cybersader commented 2 months ago

It might be the case that this is an issue with Attachment Management as well. If your plugin is just a better version of that, then let me know 😆👍

Can you clarify how the plugin accounts for "files with known names?"

mnaoumov commented 1 month ago

@cybersader please provide a test vault and a video to demonstrate how you want it to be improved