← Back to team overview

zim-wiki team mailing list archive

Re: Attachments management


Hi everyone,

Le 24/05/2020 à 12:23, Alessia Moretti a écrit :
> Thanks Marco for your answer. I usually export in html with one of the
> default template. I'm using linux (Xubuntu) and I think there should be
> a similar comand line tool. I just wanted to know how many and which
> attachments there are in the whole zim notebook (with its
> subdirectories) to check if everything is done. I think I've to run some
> command like ls(?) recursively against the notebook top level directory.
> I'm not very knowledgeable of the command like though.


On the command line under Linux, there are several possibilities, but
you can try with find

On my Linux, the following command does the trick:
find -type f -not -iname '*.txt*' -not -path '*/.git/*' -not -name
'*.zim*' -not -name '.gitignore'

Some explanations:
The command looks for all files that are not of type txt and excluding
some specific paths and displays them on the screen.
I place myself first in the notebook folder, it's not mandatory you can
add the notebook path just after find
I'm using the version control plugin, so the exclusions for .git and
.gitignore if you don't use this plugin you can remove them.