example programs in shell scripting

label Programming
account_circle Unassigned
schedule 3 Days
account_balance_wallet $5

unix shell scripting programs
Aug 21st, 2013
Example Shell Script: Convert Filenames to Lowercase 6/8
A script to convert the specified filenames to lower case.


if test $# = 0
then
echo "Usage $0: <files>" 1>&2
exit 1
fi

for filename in "$@"
do
new_filename=`echo "$filename" | tr A-Z a-z`
test "$filename" = "$new_filename" && continue
if test -r "$new_filename"
then
echo "$0: $new_filename exists" 1>&2
elif test -e "$filename"
then
mv "$filename" "$new_filename"
else
echo "$0: $filename not found" 1>&2
fi
done

http://www.cse.unsw.edu.au/~cs2041/12s2/lec/shell/examples.notes.html
Aug 30th, 2013

Did you know? You can earn $20 for every friend you invite to Studypool!
Click here to
Refer a Friend
...
Aug 21st, 2013
...
Aug 21st, 2013
Sep 22nd, 2017
check_circle
Mark as Final Answer
check_circle
Unmark as Final Answer
check_circle
Final Answer

Secure Information

Content will be erased after question is completed.

check_circle
Final Answer