joyent/smartos-live — pull request #173 by MerlinDMC (2013-02-09 20:15:37+00:00)
Title: add validate commands for create and update json files for GH-153

To make @konobi happy and fix GH-153 this implements two validation commands:
```
vmadm validate create [-f ]
vmadm validate update brand [-f ]
```

I left the validation of receive JSON out because I think nobody will unbundle and edit those files.

I did change the `main()` callback because on failure `flushLogs` was called twice and sometimes the wrong one did call `process.exit(0)` which resulted in a zero exit code on failure.