Skip to content

Package action to remove unused images from image folder #3

@chrahunt

Description

@chrahunt

I use this extension a lot for notes, and often take screenshots to embed in the notes themselves. I currently use the file in folder setting and It can be kind of a pain to refactor notes and have to worry about going back into the images folder and deleting the unused images.

Would it be possible to add a feature to go through and remove unused images from the images folder? Get the list of files in the folder that would correspond to this markdown document, get the list of images referenced in the document, take the diff and prompt for deletion. I don't see an obvious reason to have anything other than a simple dialog with a list of the images to be deleted and asking for confirmation, but others may have different requirements. For user comfort, it could also mention the number of images that were found in the images folder that are used in the current document, just so people can see the correct folder was selected.

I could see this going in either the context menu for a document tab, or available from Packages > Markclip.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions