[KPhotoAlbum] kpa-util

Robert Krawitz rlk at alum.mit.edu
Sun Mar 8 02:19:04 GMT 2020


I'm fiddling around with extensions to kpa-merge, which I'm calling
kpa-util (I haven't added it in yet).  Currently it supports the
following operations:

- merge (as current)
- clean (as current)
- add-item <category> [--parent parent] items...
- add-tag <category> items... <<< file-list (on stdin)

Note that there's no add-category -- for now, that has to be done
manually because of all the other attributes involved.  Also, there
aren't any remove options; those are more complicated.  Removing tags
from files wouldn't be hard; removing whole categories would also be
straightforward, but removing items would be a bit thorny because of
the member-group relationships.

Anybody interested in playing with it, if I add it to a branch?

My motivation in doing this is that I've applied keywords to each game
I've photographed over the past dozen seasons, which has made my
keyword list a real mess.  I'm thinking that instead I'll add them as
member-group relationships under Season, e. g.

Season/2019-2020/MIT-Wheaton Men's Basketball 2020-02-08

but for obvious reasons I don't want to do all of this by hand in the
GUI.  kpa-util is as efficient as kpa-merge (i. e. not very), but even
if I have to leave it run for many hours chugging through this, it
really doesn't matter.

It would be a lot more efficient if I could have it process multiple
commands in one shot; the difficulty is working out a syntax for it.
I suppose for add-tag and the hypothetical remove-tag there could be
an input syntax something like

<file> +<cat:tag> -<cat1:tag1>

but any of these things could have spaces, colons, and potentially
even newlines in them.  Suggestions would be welcome.
-- 
Robert Krawitz                                     <rlk at alum.mit.edu>

***  MIT Engineers   A Proud Tradition   http://mitathletics.com  ***
Member of the League for Programming Freedom  --  http://ProgFree.org
Project lead for Gutenprint   --    http://gimp-print.sourceforge.net

"Linux doesn't dictate how I work, I dictate how Linux works."
--Eric Crampton



More information about the Kphotoalbum mailing list