From: Steven Baltakatei Sandoval Date: Tue, 11 Aug 2026 18:52:15 +0000 (+0000) Subject: chore(user/gthumb/prune.org):Minor fixes X-Git-Url: https://zdv2.bktei.com/gitweb/BK-2020-03.git/commitdiff_plain/7e89e076ee2c19063b9399a2ca84bc22717e9c5c?hp=25990e39198e6c7e584a1399ddd5d489a7b826a8 chore(user/gthumb/prune.org):Minor fixes --- diff --git a/user/gthumb/prune.org b/user/gthumb/prune.org index d9d211e..81a6d29 100644 --- a/user/gthumb/prune.org +++ b/user/gthumb/prune.org @@ -1,5 +1,5 @@ #+AUTHOR: Steven Baltakatei Sandoval -#+DATE: 2026-08-01 +#+DATE: 2026-08-02 #+TITLE: gThumb prune ** Summary @@ -11,7 +11,7 @@ gThumb. The method centers around a Bash script named ~gthumb-prune.sh~ which may be bound to a gThumb keyboard shortcut to quickly move selected image files to a desired location. The Bash script is run by a short -shell script specified in gThumbʼs 🔧 → Personalize… menu. +shell script specified in gThumbʼs 🔧 → Personalize… menu. Additionally, sidecar files as well as associated files sharing the same file name stem (i.e. ~../*/DSC00001.*~) are also grouped and moved to the desired location. @@ -39,8 +39,8 @@ locations: ├── DSC00001.JPG.ots ├── DSC00002.JPG ├── DSC00002.JPG.ots - ├── DSC00002.JPG - └── DSC00002.JPG.ots + ├── DSC00003.JPG + └── DSC00003.JPG.ots #+end_example Let us say gThumb has the ~JPG~ directory open and we have selected @@ -65,7 +65,7 @@ Command~ window. Click the *Ok* button to close the ~Commands~ window. Now, with ~DSC00002.JPG~ selected, press ~Shift+K~ on your keyboard. The image should disappear from view and a new directory -should appear in the the left navbar, reflecting a new directory structure. +should appear in the left navbar, reflecting a new directory structure. #+begin_example . @@ -88,7 +88,7 @@ should appear in the the left navbar, reflecting a new directory structure. └── DSC00002.JPG.ots #+end_example -The ~DSC0002.*~ files (4 in total) have been moved to now reside +The ~DSC00002.*~ files (4 in total) have been moved to now reside within a ~keep~ directory with their ~JPG~ and ~ARW~ subdirectory structure preserved. Thus, the ~./JPG/~ and ~./ARW/~ directories have been pruned. @@ -134,7 +134,7 @@ changed to: ├── DSC00001.JPG.ots ├── DSC00003.JPG └── DSC00003.JPG.ots -#+end_Example +#+end_example So, the contents of ~./JPG/~ may be pruned by selecting files you want to keep and pressing ~Shift+K~ and by selecting files you want to @@ -142,16 +142,16 @@ trash and pressing ~Shift+T~. Then, if you are really sure about deleting the undesired files, delete the contents of ~.trash~ via the terminal command: -: $ rm -r ./.trash/* +: $ rm -r ./.trash ** Code gthumb-prune.sh: -#+begin_code +#+begin_src bash #!/bin/bash # Desc: Prunes files selected by gThumb. # Note: Moves files into a directory with a specified name. -# Usage: gthumb-prune.sh [STR dirname] [FILES…] +# Usage: gthumb-prune.sh DIRNAME FILES… # Example: $HOME/.local/bin/gthumb-prune.sh keep %F # If '%F' expanded to `~/Pics/MyJPGs/DSC00001.JPG`, then # "$HOME/Pics/*/DSC00001.*" files are moved to: @@ -253,5 +253,4 @@ main "$@" 1>>"$fdebug" 2>&1; # Author: Steven Baltakatei Sandoval # License: GPLv3+ -#+end_code - +#+end_src