mmv gibt stets collision aus ...

testit

Well-Known Member
Hallo,

ich möchte mit Hilfe von mmv rekursiv die Extensions mehrere Dateien in einem bestimmten Verzeichnis und darunterliegend umbenennen.

Folgender Manpage-Auszug von mmv gibt an, dass dies gehen müsste:

Code:
Note that paths are allowed in the patterns, and wildcards
       may  be  intermingled  with  slashes arbitrarily.  The ';'
       wildcard is useful for matching files at any depth in  the
       directory  tree.  It matches the same as "*/" repeated any
       number of times, including zero, and can only occur either
       at  the beginning of the pattern or following a '/'.  Thus
       [B]";*.c" will match all ".c" files in or below  the  current
       directory,[/B]  while  "/;*.c" will match them anywhere on the
       file system.

Ein einfaches mmv ';*.sample' '#1.bak' führt bei mir aber zu einem "collision"-Fehler:

# ls
apache syslog.sample test

# mmv ';*.sample' '#1.bak'

syslog.sample , test/sysl.sample -> #1.bak : collision.
Nothing done.

Weiss jemand Rat?

Danke und nette Grüsse
testit
 
GaTh3N schrieb:
Ja,
Code:
mmv ';*.sample' '=1=2.bak'
müsste funktionieren.
Gruß, Simon

Hi,

super - vielen Dank! Es funktionierte!

Ich frage mich nur, wieso alle Beispiele, die ich sonst so finden konnte, mit der # arbeiteten?

Wie bist Du auf das = gekommen?


Netter Gruss
testit
 
testit schrieb:
Ich frage mich nur, wieso alle Beispiele, die ich sonst so finden konnte, mit der # arbeiteten?

Wie bist Du auf das = gekommen?

man mmv ;)
Aber ich weiß auch nicht wieso manchmal # verwendet wird. Beim mmv aus den Ports ist es jedenfalls =
 
Zurück
Oben