[KPhotoAlbum] KPhotoAlbumKPA import/export, first experiences

Wes Hardaker wjhns25 at hardakers.net
Mon Jan 5 17:00:24 GMT 2009


>>>>> On Sun, 4 Jan 2009 08:19:31 +0200, "Risto H. Kurppa" <risto at kurppa.fi> said:

RHK> So I was able to import/export but it was a pain the first time - and
RHK> the next time I do it, I have to remember to create one .kim for each
RHK> folder (will be a pain if you want to move many folders to another
RHK> database...!) and give the proper folder names in the target folder
RHK> field (I think this is weird as the .kim xml anyway contains the
RHK> folder name in it)

I too keep a directory-based organized system that *must* be kept that
way because of other apps needing the by-directory sorting method.

What I've done in the past is write a script (to show how old it is,
it's called "kimdbmerge" because it was originally written for kimdaba,
the previous name for kphotoalbum) to take two index.xml files and merge
them together.  This way I could do exactly what you're describing:

1) create a directory on my laptop and sort through my fresh copies
   completely far away from my master server with the master set of
   images.
2) when I get home, plonk the directory with the new images into the
   right place on the main server with nearly 30k images.
3) tell kimdbmerge to auto-add all the new images into the main
   index.xml file.
4) launch kphotoalbum with the full view

This actually worked fairly well.  That being said, I'm currently
rewriting kimdbmerge to use a different XML sucker-upper that's a bit
faster.  I'll happily release it when I finish it.  I'm actually working
on a number of other patches to kphotoalbum that I'll likely release
soon as well (one of which is about done).

Ideally, what I think *should* happen is that if kphotoalbum does it's
start up scan on say "/img" and notices new images in
"/img/trips/2008-01-10-party-hardy" and finds a
"/img/trips/2008-01-10-party-hardy/index.xml" file it'll auto-recognize
it and ask if you want to merge it in.  *this* I think is the best way
forward for everyone and I've been thinking about hacking the code to
make this happen (but I suspect I'd need to learn a lot about the
kphotoalbum architecture which I don't know right now).

The import/export features right now are completely unusable for the way
I need to store my pictures for the reasons you've pointed out.  Most
importantly, the import/export routines don't keep track of
subdirectories properly...  It's a non-starter for me unfortunately.
-- 
"In the bathtub of history the truth is harder to hold than the soap,
 and much more difficult to find."  -- Terry Pratchett



More information about the Kphotoalbum mailing list