housekeeping script to remove dead images

I use mnemosyne daily to learn plant identification and make heavy use of images. All the images are stored in ~dougie/.mnemosyne/images and are referenced from the .mnemosyne config file in ~/.mnemosyne/default.mem. Sometimes I delete cards that I don’t like, are poorly phrased, or have something wrong about them. This doesn’t delete the corresponding image. I … Continue reading “housekeeping script to remove dead images”

I use mnemosyne daily to learn plant identification and make heavy use of images. All the images are stored in ~dougie/.mnemosyne/images and are referenced from the .mnemosyne config file in ~/.mnemosyne/default.mem.

Sometimes I delete cards that I don’t like, are poorly phrased, or have something wrong about them. This doesn’t delete the corresponding image.

I need to write a shell script to scan the default.mem file and extract all the filenames for the image jpegs, then check whether they exist. No, hang it, that’s the wrong way round. Although that would be useful too as sometimes I delete an image but not a card.

Ah, so it has to be a two-way script. Checking for orphans both ways. Are there images that are not in cards? And are there cards that reference images that aren’t there?

I should probably also wait until version 2.x of mnemosyne hits the streets in case there are any layout changes.
 

(Visited 8 times, 1 visits today)

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.