Comp 141 Class 11 notes

July 31

The Final Exam on Sakai opens Wednesday Aug 6 at noon, and closes at the end of Thursday Aug 7.

Sometimes people will use this style in bash scripts:

[[ -f $foo ]] || echo "$foo not found"; exit

The || represents "or", and the righthand side is executed only if the lefthand side is false. The [[ (but not [) returns a result code. So this is equivalent to

if [ ! -f $foo ] ; then echo "$foo not found"; fi

The latter is much more readable.

The = sign in bash assignments cannot have spaces on either side

    foo = bar    # looks like the command "foo", with arguments "=" and "bar"

    foo= bar    # looks like the command "bar", but with foo set to the empty string in the command's environment

networking

ssh

arrays

web servers

identifying containers

Sphinx

Study guide