Fixed more versioning issues

Although the nodewebkit npm package tracks the same versions as node-webkit, it can also have patch/build versions which we need to filter out.
Fix and add a bit of error handling
Merge pull request #36 from 1j01/api-cli

Fix and add a bit of error handling
Merge branch 'develop' into master
Merge pull request #27 from badsyntax/version_fixes