Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Files used in canvas are detected as orphans #43

Open
MrJGao opened this issue Apr 18, 2023 · 4 comments
Open

Files used in canvas are detected as orphans #43

MrJGao opened this issue Apr 18, 2023 · 4 comments

Comments

@MrJGao
Copy link

MrJGao commented Apr 18, 2023

I found that when I insert an image, for example, into an obsidian canvas file, the image would be detected as an orphan when using the plugin. More importantly, I'd like to delete image files that are not used as attachments, but when I use the "delete certain orphan file types" command, the image I just inserted would be deleted.

Is there a way to exclude files used in canvas? Thanks.

@Vinzent03
Copy link
Owner

I can reproduce, but I don't know how to fix that. Normally, Obsidian tracks the links and embeds per file in a cache, but it does not for canvas files.

@MrJGao
Copy link
Author

MrJGao commented Apr 22, 2023

I can reproduce, but I don't know how to fix that. Normally, Obsidian tracks the links and embeds per file in a cache, but it does not for canvas files.

Thanks for your response.

I have an idea but not sure if it's doable. I noticed that the *.canvas files are in JSON format and they can be opened by any text editor. The *.canvas files listed all the source materials they use. So, can we read the *.canvas files manually using this extension and then find the linked images/files? Thanks.

@Vinzent03
Copy link
Owner

You are right, it's technical possible, but it's a bit tedious and more complicated to implement. Don't know when I get the time for this.

@felipemeres
Copy link

I would really appreciate having canvas links as part of the orphaned files search as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants