Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Problems with piping on windows #749

Merged
merged 1 commit into from Jan 2, 2013

Conversation

Projects
None yet
2 participants

when you run ex.

jshint . > error.log

the output gets truncated if its longer
the boolean flag is needed if node version < 0.6.4 (if i have read the commit log correctly), after that it was patched so it doesn't run into a recursive loop ( see discussion )

@valueof valueof commented on the diff Dec 5, 2012

src/cli/cli.js
- // Avoid stdout cutoff in Node 0.4.x, also supports 0.5.x.
- // See https://github.com/joyent/node/issues/1669
-
- function exit() { process.exit(passed ? 0 : 2); }
-
- try {
- if (!process.stdout.flush()) {
- process.stdout.once("drain", exit);
- } else {
- exit();
- }
- } catch (err) {
- exit();
- }
+ var exiting = false;
+ process.on('exit', function() {
@valueof

valueof Dec 5, 2012

Owner

How does this event get triggered?

@Bonuspunkt

Bonuspunkt Dec 6, 2012

by node itself - Emitted when the process is about to exit.
http://nodejs.org/docs/latest/api/process.html#process_event_exit

@valueof valueof added a commit that referenced this pull request Jan 2, 2013

@valueof valueof Merge pull request #749 from Bonuspunkt/master
Problems with piping on windows
815dae1

@valueof valueof merged commit 815dae1 into jshint:master Jan 2, 2013

1 check passed

default The Travis build passed
Details
Owner

valueof commented Jan 2, 2013

Thanks!

Owner

valueof commented Jan 2, 2013

Had to revert this patch because NPM was complaining about memory leaks.

@valueof valueof added a commit that referenced this pull request Jan 2, 2013

@valueof valueof Revert "Merge pull request #749 from Bonuspunkt/master"
This reverts commit 815dae1, reversing
changes made to 0f116f6.
cf71120

@jugglinmike jugglinmike added a commit to jugglinmike/jshint that referenced this pull request Oct 21, 2014

@valueof @jugglinmike valueof + jugglinmike Merge pull request #749 from Bonuspunkt/master
Problems with piping on windows
0ad49f9

@jugglinmike jugglinmike added a commit to jugglinmike/jshint that referenced this pull request Oct 21, 2014

@valueof @jugglinmike valueof + jugglinmike Revert "Merge pull request #749 from Bonuspunkt/master"
This reverts commit 815dae1, reversing
changes made to 0f116f6.
458be6e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment