How to tell darktable that images have moved?

Hi, as noted just above this post, I find an error when executing this script. Any idea who the author is to whom I could report this error?

OH, yes I installed something called ‘sqlite3’ via Synaptic (no mention of the ‘binary’ bit though). I assume everything required is now there, because the error looks like it is within the script.

Hah! this worked just fine, allowing me to purge a few hundred ‘lost’ images very quickly. Strangely my technique of invoking ‘sh purge_non_existing_images.sh’ creates the script error previously mentioned.

Thanks for your advice. Minor hill of ignorance ascended.

1 Like

sh is usually not the same as bash, which this script assumes. Probably it would have worked with bash purge_non_existing_images.sh.

Not strange, the script requires features specific to the bash shell, but when you invoke a shell using sh you only get a subset of bash shell features, in order to maintain compatibility with the original bourne shell. This is why you were seeing the error – the script was trying to use bash features not available within the sh subset. If you put bash purge_non_existing_images.sh, it should work, or alternatively if execute permission if set of the file, and invoke the execution of the file with ./purge_non_existing_images.sh, the #! line at the start of the file will cause the file to be run with bash shell.

OK, thanks for this explanation: I got into this situation through not understanding enough about the implications of the differences between 'sh; and ‘bash’ - probably because i never really had to use, or learn (not the same thing) any form of what I generally call ‘Unix’, including iOS.

Script runs fine, as you say.

1 Like