Zoek en verwijder items uit de bibliotheekdatabase die verwijzen naar afbeeldingen die niet langer in het bestandssysteem bestaan. Je moet Ansel sluiten voordat je dit script uitvoert.

Het script kan worden aangeroepen met de volgende opdrachtregelparameters:

1purge_non_existing_images.sh [-c|--configdir <path>]
2                             [-l|--library <path>]
3                             [-p|--purge]

Voer het script uit zonder opties om een “dry run” uit te voeren, die een rapport genereert van de ontbrekende bestanden zonder enige wijzigingen in de database door te voeren.

De beschikbare opties zijn:

-c|--configdir <pad>
geef het pad op naar de Ansel-configuratiemap die door het script moet worden gebruikt. Als deze optie niet wordt geboden, wordt de standaardlocatie van de configuratiemap gebruikt.
-l|--bibliotheek <pad>
geef het pad op naar het databasebestand library.db dat door het script moet worden geanalyseerd. Als deze optie niet is opgegeven, wordt de standaard bestandslocatie library.db gebruikt.
-p|--purge
Verwijder daadwerkelijk alle vermeldingen in de database die verwijzen naar niet-bestaande bestanden. Als de optie niet wordt geboden, wordt een rapport afgedrukt zonder wijzigingen in de database door te voeren.

Opmerkingen:

  1. The script must be run in a unix shell, and the sqlite3 client must be available in the command search path. For Linux systems, this will normally not be an issue.

  2. For Windows systems, you will normally need the MSYS2 environment to be installed, as described in the instructions for building Ansel in a Windows environment. If you installed Ansel using the standard Windows installer package, the location of the script would normally be something like: C:\Program Files\Ansel\share\Ansel\tools\purge_non_existing_images.sh.

  3. For macOS systems, the Terminal application provides a shell, and the sqlite3 client is provided by the operating system by default. If Ansel was installed using an application bundle from a dmg image, then the default location for the script would be /Applications/Ansel.app/Contents/Resources/share/Ansel/tools/purge_non_existing_images.sh

  4. The delete operation can’t be undone. It is therefore strongly recommended that you take a backup of the database before purging any entries.