Fix compilation command generation issue

remove spurious --next for final command.
generate commands arguments as an array like so: ['-main', 'Main', '-js', 'output/main.js']
Put back log
more functional js
Merge pull request #7 from sledorze/master

Fix compilation command generation