|
chmod u+rwx,go+rx-w $*
chmod u+rwx,go-rwx $*
directories:
chmod u+rwx,g-rwx,o+x-rw $*files (web pages, images, etc):
chmod u+rwx,g-rwx,o+r-xw $*CGI scripts:
chmod u+rwx,g-rwx,o+rx-w $*"norm" could of course replace all 3 if you don't mind granting more access than strictly necessary.
e.g. Want to be able to repeatedly run:
rmifexists *.bak
and not get error message if no *.bak files found.
for i in $*
do
if test -f $i
then
rm $i
fi
done
|
Why not:
if test -f $*
then
rm $*
fi
cd $HOME du | sort -n
rmifexists *% rmifexists .*% rmifexists *~ rmifexists .*~ rmifexists *.bak rmifexists .*.bak rmifexists *.BAK rmifexists .*.BAKCertainly easier than having to point-and-click each one.
On Internet since 1987.