code highlight, syntax fixes

 - added JavaScript and shell code highlight
 - fixed some missing semicolon
 - replaced multiple var declarations with one