X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=torn;h=55822266cbd0bab69bd39f2b8b5d7c28ef7b4bb7;hb=ed78e9743f22a379609932ad6b575e04f3fb9bd8;hp=cc0d81cb3d8808958b67fca4bc3dafbdc046f01c;hpb=4289b6bcf4e4f71e1ebe2bf1512a1b333eb229f1;p=torn.git diff --git a/torn b/torn index cc0d81c..5582226 100755 --- a/torn +++ b/torn @@ -1,17 +1,16 @@ #!/usr/bin/env perl # torn - Musical files renaming with russian language transliteration -# Copyright (C) 2007-2018 Sergey Matveev (stargrave@stargrave.org) +# Copyright (C) 2007-2020 Sergey Matveev (stargrave@stargrave.org) # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. +# the Free Software Foundation, version 3 of the License. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -# +# # You should have received a copy of the GNU General Public License # along with this program. If not, see . @@ -66,14 +65,18 @@ my $src; my $dst; my $src_filename; -print "torn version $VERSION, Copyright (C) 2007-2018 Sergey Matveev +if ($#ARGV >= 0) { + print "torn version $VERSION, Copyright (C) 2007-2020 Sergey Matveev torn comes with ABSOLUTELY NO WARRANTY. This is free software, -and you are welcome to redistribute it under certain conditions.\n\n"; +and you are welcome to redistribute it under certain conditions.\n +Usage: just run inside the directory. Look for POD inside the script itself.\n"; +}; opendir DIR, "." or die "Can not open directory\n"; foreach (sort readdir DIR) { # Skip directory itself next if /^\.{1,2}$/; + next if -d; $src_filename = $_; $src = decode "utf-8", $src_filename;