School of Computing. Dublin City University.
Online coding site: Ancient Brain
coders JavaScript worlds
# list files given in the argument: ls$1
# what caused this do you think? Echo "some text" Ls -al
# 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