mirror of
https://github.com/iiab/iiab.git
synced 2025-03-09 15:40:17 +00:00
Update iiab-diagnostics
This commit is contained in:
parent
340b3a8016
commit
047606c05e
1 changed files with 11 additions and 8 deletions
|
@ -38,15 +38,18 @@ function cat_file_raw() { # $1 = path/filename; $2 = # of lines, for tail
|
|||
tail -$2 $1 | iconv -t UTF-8//IGNORE >> $outfile
|
||||
fi
|
||||
echo >> $outfile
|
||||
elif [ -h $1 ]; then
|
||||
ls -l $1 >> $outfile
|
||||
echo >> $outfile
|
||||
echo "SYMLINK DOES NOT LEAD TO A REGULAR FILE!" >> $outfile
|
||||
echo >> $outfile
|
||||
elif [ -d $1 ]; then
|
||||
ls -ld $1 >> $outfile
|
||||
echo >> $outfile
|
||||
echo "THIS IS A DIRECTORY NOT A FILE!" >> $outfile
|
||||
echo >> $outfile
|
||||
else
|
||||
if [ -d $1 ]; then
|
||||
ls -ld $1 >> $outfile
|
||||
echo >> $outfile
|
||||
echo "THIS IS A DIRECTORY NOT A FILE!" >> $outfile
|
||||
echo >> $outfile
|
||||
else
|
||||
echo "FILE DOES NOT EXIST: $1" >> $outfile
|
||||
fi
|
||||
echo "FILE DOES NOT EXIST: $1" >> $outfile
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue