1 #+AUTHOR: Steven Baltakatei Sandoval
6 This command moves a single selected file ~dir1/file123.ext~ to be
7 kept in a ~keep/~ directory along with any adjacent files that share
8 the same stem located within the same directory
9 (e.g. ~dir1/file123.*~). Also moved are matching files in directories
10 neighboring the originalʼs parent directory (e.g. ~dir2/file123.*~).
11 The destination trash directory is ~keep~; parent directories ~JPG/~
12 and ~ARW/~ (e.g. ~dir1~, ~dir2~) are preserved within ~keep/~.
16 gThumb version: ~3.12.6~
17 Suggested keyboard shortcut: ~Shift + T~
20 *keep* is useful for pruning photos with multiple format extensions
21 with each extension type in a separate directory. For example, letʼs
22 say a ~JPG/~ directory contains ~JPG/DSC01001.JPG~,
23 ~JPG/DSC01001.JPG.ots~ and a ~ARW/~ directory contains
24 ~ARW/DSC01001.ARW~. With ~JPG/DSC01001.JPG~ selected in gThumb, a
25 ~keep~ directory is created next to ~JPG/~ and ~ARW/~. Then, the
26 following moves are performed:
28 - ~JPG/DSC01001.JPG~ is moved to ~keep/JPG/DSC01001.JPG~
29 - ~JPG/DSC01001.JPG.ots~ is moved to ~keep/JPG/DSC01001.JPG.ots~
30 - ~ARW/DSC01001.ARW~ is moved to ~keep/ARW/DSC01001.ARW~
32 Thus, by browsing ~JPG/~ in gThumb and performing *keep* on defsired
33 photos, related photos from not only ~JPG/~, ~ARW/~ and
34 other similar directories are moved for preservation in ~keep/~.
36 Then, it is upon the user to archive the contents of ~keep/~ to.
42 dbf=/tmp/gtlogkeep.txt;
44 fBase="$(basename "$f")";
46 dppar="$(dirname %P)";
47 dKeep="${dppar}/keep";
48 dKeepJpg="${dKeep}/JPG/";
49 dKeepArw="${dKeep}/ARW/";
50 mkdir -p "$dKeep" "$dKeepJpg" "$dKeepArw";
51 printf "%s\n" "$dbf" "$f" "$fBase" "$fne" "$dppar" "$dKeep" 1>"$dbf" 2>&1;
52 mv -n -t "$dKeepJpg" "${dppar}/"*"/${fne}.JPG"*;
53 mv -n -t "$dKeepArw" "${dppar}/"*"/${fne}.ARW"*;
59 dbf=/tmp/gtlogkeep.txt; f="%F"; fBase="$(basename "$f")"; fne="${fBase%.*}"; dppar="$(dirname %P)"; dKeep="${dppar}/keep"; dKeepJpg="${dKeep}/JPG/"; dKeepArw="${dKeep}/ARW/"; mkdir -p "$dKeep" "$dKeepJpg" "$dKeepArw"; printf "%s\n" "$dbf" "$f" "$fBase" "$fne" "$dppar" "$dKeep" 1>"$dbf" 2>&1; mv -n -t "$dKeepJpg" "${dppar}/"*"/${fne}.JPG"*; mv -n -t "$dKeepArw" "${dppar}/"*"/${fne}.ARW"*; sleep 1;