24,7 → 24,7 |
mesg="$1" |
|
echo "Usage: $progname directory" |
echo $mesg |
echo "$mesg" |
} |
|
# |
43,11 → 43,11 |
for file in $files |
do |
pfile=$curdir2/$file # file including path |
if [ $file != ".." -a $file != "." ] |
if [ "$file" != ".." -a "$file" != "." ] |
then |
if [ -d "$file" -a ! -L "$file" ] |
then |
echo $pfile |
echo "$pfile" |
traverse "$file" |
else |
if [ -f $file -o -L $file ] |
67,8 → 67,8 |
{ |
directory=$1 |
|
echo $directory |
traverse $directory |
echo "$directory" |
traverse "$directory" |
} |
|
# ============================================================================= |
75,13 → 75,13 |
# MAIN |
# ============================================================================= |
|
progname=$(basename $0) |
progname=$(basename "$0") |
if [ $# -eq 1 ] |
then |
directory=$1 |
if [ -d $directory ] |
if [ -d "$directory" ] |
then |
start_traverse $directory |
start_traverse "$directory" |
else |
Usage "ERROR: No a directory : $directory" |
fi |