![]() |
![]() |
|
|
|||||||
| Linux, UNIX, Open Source Rat & Tat bei Problemen und Fragen rund um GNU/Linux, BSD und sonstige UNIXe |
![]() |
|
|
Themen-Optionen | Ansicht |
|
|
#11 |
|
Inventar
![]() Registriert seit: 05.01.2000
Beiträge: 3.812
|
Na geht nur mit Perl
![]() Das müssen Scripten mit Java sein....ich kenne eigentlich nur das Updaten von DW als Lösung. Unbennen ist aber auch eine Lösung......... Sloter |
|
|
|
|
|
#12 |
|
Inventar
![]() Registriert seit: 24.09.2001
Beiträge: 7.335
|
Geht leider auch ohne Perl:
Code:
################################################################ # Convert all filenames to uppercase or lowercase. # Use like ls. I.e. shell expansion to find filenames. # -l2u to convert lower to upper. # Otherwise converts upper to lower. # Reports how many files were changed. ################################################################ # $@. op=$1 if test $op = "-l2u"; then shift fi i=0 while true; do if test -z $1; then echo -n $i file if test $i -ne 1; then echo -n s fi echo " converted." exit 0 fi if test ! -e $1; then echo "$1 doesn't exist." elif test ! -w $1; then echo $1 is not writable. elif test $op = "-l2u"; then if test `echo $1 | grep [a-z]`; then mv -i $1 `echo $1 | tr a-z A-Z` if test $? -eq 0; then let i+=1 fi fi else if test `echo $1 | grep [A-Z]`; then mv -i $1 `echo $1 | tr A-Z a-z` if test $? -eq 0; then let i+=1 fi fi fi shift done
____________________________________
Weiterhin zu finden auf http://martin.leyrer.priv.at , http://twitter.com/leyrer , http://www.debattierclub.net/ , http://www.tratschen.at/ und via Instant Messaging auf Jabber: m3 <ät> cargal.org . |
|
|
|
|
|
#13 |
|
Inventar
![]() Registriert seit: 08.02.2000
Beiträge: 1.696
|
Danke! Ganz hab ich no net verstanden, was das Ding macht, aber wird schon noch...
Und an Fehler hab ich gefunden: Code:
if test $op = "-l2u"; then shift fi Code:
if test $op -e "-l2u"; then shift fi
____________________________________
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you. |
|
|
|
|
|
#14 |
|
Inventar
![]() Registriert seit: 08.02.2000
Beiträge: 1.696
|
Also... soviel mal vorweg -> es läuft!!!!!!!!!!!!
Groß/kleinschreibung war es nicht, aber ein config-problem... wenn man sich die msvcrt.dll von einem Win98 kopiert und explizit angibt, dann funkt alles! mfg
____________________________________
Sex is like hacking. You get in, you get out, and you hope you didnt leave something behind that can be traced back to you. |
|
|
|
![]() |
| Aktive Benutzer in diesem Thema: 1 (Registrierte Benutzer: 0, Gäste: 1) | |
|
|