summaryrefslogtreecommitdiffstats
path: root/digitaglinktree-1.8.4beta
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2013-12-28 20:08:54 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2013-12-28 20:08:54 +0100
commit3701f3f0dcf0f416eaa89d65bc9974161b110e5c (patch)
tree1c073419492908601ff515a5d88faa99e98b8f7e /digitaglinktree-1.8.4beta
parentd4ae906c8f890d1ad5635ae1940b7e9e8b0ffc38 (diff)
downloaddigikam-android-master.tar.gz
digikam-android-master.tar.bz2
digikam-android-master.zip
regenerate the original folder (album) structure for each tagHEADmaster
Diffstat (limited to 'digitaglinktree-1.8.4beta')
-rwxr-xr-xdigitaglinktree-1.8.4beta13
1 files changed, 12 insertions, 1 deletions
diff --git a/digitaglinktree-1.8.4beta b/digitaglinktree-1.8.4beta
index 1ebcdb6..c0625bf 100755
--- a/digitaglinktree-1.8.4beta
+++ b/digitaglinktree-1.8.4beta
@@ -441,7 +441,17 @@ sub createLinkTree{
if(length($opt_absolute)){
# Create link
$sourceDir="${photoRootDir}$path/$image";
- $destDir="${linktreeRootDir}/$tag/$linkName";
+ $destDir="${linktreeRootDir}/$tag$path/$linkName";
+
+ print "$sourceDir -> $destDir\n";
+
+ if ( ! -d "${linktreeRootDir}/$tag$path" ) {
+ $ret=mkpath("${linktreeRootDir}/$tag$path", 0, 0755);
+ }
+
+ if( !$ret ){
+ die "Cannot mkdir \"${linktreeRootDir}/$tag$path\"\n";
+ }
}else{
# Get relative path from absolute one
# $rel=File::Spec->abs2rel( $path, $base ) ;
@@ -837,6 +847,7 @@ sub usage{
" -C If -A <archdir> was given this option will put hardlinks of all\n",
" photos in the \"$archiveDirPhotos\" directory not only of those with tags.\n",
" -a Create absolute symbolic links instead of relative ones \n",
+ " and regenerate the original folder (album) structure for each tag \n",
" -H Use hard links instead of symbolic links in linktree. \n",
" -Y Add Year directory below each tag directory \n",
" -f If there are hierarchical tags (tags that have subtags) \n",