process.exit stopping my CLI tool in Travis builds #18

Closed
davglass opened this Issue Apr 4, 2013 · 4 comments

Comments

Projects
None yet
2 participants
Contributor

davglass commented Apr 4, 2013

Why is there a process.exit here:
https://github.com/hij1nx/complete/blob/master/lib/complete.js#L162

Shouldn't this throw and let us trap it?

Here is an example of something using my CLI tool yogi and under Travis it's failing with a process.exit(0) and not letting my cli tool continue.

https://travis-ci.org/yui/yui3/jobs/6053540

I would rather have it throw and trappable so they can see the warning but not exit the process.

Owner

0x00A commented Apr 4, 2013

Ah, ok. The reason it has this is to prevent the program from continuing prior to installation of the completion script. this could throw as opposed to exiting the process without complication. Pull request absolutely welcome. :D

Contributor

davglass commented Apr 4, 2013

Great, I'll get to this in a bit. I wanted to make sure it wasn't on purpose.

0x00A closed this in 2513802 Apr 5, 2013

@0x00A 0x00A added a commit that referenced this issue Apr 5, 2013

@0x00A 0x00A Merge pull request #19 from davglass/throw
Fixes #18 - Throw on complete failure instead of exiting the process
cbe9ce8
Owner

0x00A commented Apr 5, 2013

0.4.3 Published! Thanks Dav!

Contributor

davglass commented Apr 5, 2013

Awesome! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment