Benutzer-Werkzeuge

Webseiten-Werkzeuge


comp:deldup

Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Beide Seiten der vorigen RevisionVorhergehende Überarbeitung
Letzte ÜberarbeitungBeide Seiten der Revision
comp:deldup [2010-04-25 12:26] – typo in filename wernercomp:deldup [2010-10-08 21:08] – Fipptehler korrigiert werner
Zeile 20: Zeile 20:
 # default values for all operations # default values for all operations
 ACTION='HARD'  # create hard links ACTION='HARD'  # create hard links
-LNPARAM='--'   # parameter for th ln command+LNPARAM='--'   # parameter for the ln command
 PATTERN='*'    # files to look at PATTERN='*'    # files to look at
 DEPTH=1        # directory depth DEPTH=1        # directory depth
Zeile 65: Zeile 65:
     echo '       -h       show this help'     echo '       -h       show this help'
     echo '       -l       hardlink the duplicates to a master (default action)'     echo '       -l       hardlink the duplicates to a master (default action)'
-    echo '       -p pat   give the search pattern fur duplicate files (default: *)' +    echo '       -p pat   give the search pattern for duplicate files (default: *)' 
-    echo '                Please escape shell metacharacters, e. g. -p "\*.jpg"'+    echo '                Please escape shell metacharacters, like -p "\*.jpg"'
     echo '       -q       quiet, do not echo "examined" for each directory'     echo '       -q       quiet, do not echo "examined" for each directory'
     echo '       -s       symlink the duplicates to a master instead of hardlink'     echo '       -s       symlink the duplicates to a master instead of hardlink'
     echo '       -u       unlink the duplicates (= delete them)'     echo '       -u       unlink the duplicates (= delete them)'
 +    echo '       -v       verbose, echo each handled and compared file'
     echo '       startdir where to start searching the duplicates (default: current directory)'     echo '       startdir where to start searching the duplicates (default: current directory)'
-    echo '       -v       verbose, tell each handled and compared file' 
     echo ' '     echo ' '
 } }
Zeile 78: Zeile 78:
     HELPFILE="$1"     HELPFILE="$1"
     while read DAT ; do     while read DAT ; do
-#       MYDAT=$(echo "$DAT" | sed 's/[^\\] /\\ /g') 
-#       the script does not like that... 
         MYDAT="$DAT"         MYDAT="$DAT"
         test -x "$MYDAT" && chmod a-x -- "$MYDAT"         test -x "$MYDAT" && chmod a-x -- "$MYDAT"
Zeile 91: Zeile 89:
 DIRLIST=$( find "$DIR" -maxdepth $DEPTH -type d | tr ' ' '#' | tr "\n" " ") DIRLIST=$( find "$DIR" -maxdepth $DEPTH -type d | tr ' ' '#' | tr "\n" " ")
  
-# set -x 
 for WDIR in $DIRLIST ; do for WDIR in $DIRLIST ; do
     # get all files in the current dir     # get all files in the current dir
comp/deldup.txt · Zuletzt geändert: 2010-11-03 12:59 von werner

Falls nicht anders bezeichnet, ist der Inhalt dieses Wikis unter der folgenden Lizenz veröffentlicht: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki