X-Git-Url: http://www.git.stargrave.org/?p=torn.git;a=blobdiff_plain;f=torn;fp=torn;h=36d8c8f10bee2e2b0eda96a315866f68481711db;hp=5db4688f851ebad6a648a29e1297bf4b40b674d0;hb=252fae71d79309d40494ffa22cecfe4e48ee87bc;hpb=6077f2f6b52f33b4f82f3ebafde547bca8cdfc76 diff --git a/torn b/torn index 5db4688..36d8c8f 100755 --- a/torn +++ b/torn @@ -25,7 +25,8 @@ files and rules to convert russian filenames to translit. =head1 USAGE Simply run this script in directory where you want files and/or -directorires to be renamed. +directories to be renamed. Directories are not transliterated by +default, but you can use FORCE_DIR=1 environment variable. =head1 OVERVIEW @@ -76,7 +77,7 @@ opendir DIR, "." or die "Can not open directory\n"; foreach (sort readdir DIR) { # Skip directory itself next if /^\.{1,2}$/; - next if -d; + next if -d and not $ENV{FORCE_DIR}; $src_filename = $_; $src = decode "utf-8", $src_filename;