|
# list files given in the argument: ls$1
# find processes and kill them: # how do I know this script has never been run? for i in 'ps -f | grep textedit' do kill $i done
# what caused this do you think? Echo "some text" Ls -al
cd / cd ..
# list all files on disk, collect results in some output file: cd / ls -alR > outputfile.log
# substitute new text for old text in a number of files: read OLDTEXT read NEWTEXT for i in $* do sed -e "s|$OLDTEXT|$NEWTEXT|g" $i > $i done
# how do I know this script has never been run? find . -name $1 > /dev/null 2> /dev /null
# how do I know this script has never been run? echo "enter old text" read OLDTEXT echo "enter new text read NEWTEXT
On Internet since 1987.