New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix npm2 support #18
Fix npm2 support #18
Conversation
As of npm 2.1.8, npm run will exit with an error if the run script is not defined in package.json. Fixes #17
@@ -91,6 +92,7 @@ exports.syncBranch = function gitSyncBranch(gitDstBranch) { | |||
var src = resolveBranch('HEAD'); | |||
var dst = resolveBranch(gitDstBranch); | |||
|
|||
debug('syncing dst(%p) with src(%o)', src, dst); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
%p %o
, what do those do?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
%p
was a typo. %o
is a new feature in debug@2 for util.inspect
format, which is sometimes easier on the eyes than %j
's JSON formatting.
Would be nice to have green CI, yes. |
test please |
And we have a party. CI fix was partially a Jenkins config change and partially switching to strong-fork-syslog so 0.11.x tests pass. @sam-github PTAL. |
@sam-github I can remove the debug commit(s) before merge, if you like, but the extra debug might be useful. |
@@ -91,6 +92,7 @@ exports.syncBranch = function gitSyncBranch(gitDstBranch) { | |||
var src = resolveBranch('HEAD'); | |||
var dst = resolveBranch(gitDstBranch); | |||
|
|||
debug('syncing dst(%o) with src(%o)', src, dst); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
%o
and %p
are not documented console.log flags. http://nodejs.org/api/util.html#util_util_format_format What are they from?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
debug-js/debug#160, for the record
debug statements are good, I just don't understand that one. other than that, LGTM |
Correction, was actually added in debug 1.0.0.. though that changelog entry is the only documentation. |
Useful for debugging tests, such as discovering that the way Jenkins was configured to run the tests from a detached HEAD completely broke the git build process.
A fork of node-syslog with better support for node v0.11.x
Problem:
npm run build
fails on npm2 if there is nobuild
run-script defined.Fix: Only run
npm run build
step if there is abuild
run-script defined.The fix is easy, but I'm going to spend a few minutes trying to get CI green if I can.