Return the exit code in ScriptExecutor

Solving issue #987

Now the exit code from the script in project.json need to be zero to ensure a successful build/pack/restore.
Can we declare a const like `EXIT_SUCCESS` and compare the return value with it?