-
Notifications
You must be signed in to change notification settings - Fork 547
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
chore: remove gulp-git dependency #256
chore: remove gulp-git dependency #256
Conversation
Hey there, this should be done now. Tell me what you think – I'd squash this if you are fine with the idea |
}); | ||
|
||
let cleanError = new Error('Error: No files added to staging! Did you forget to run git add?'); | ||
throw cleanError; |
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.
Why assign the error to a variable first?
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.
Fixed
c89c06d
to
54e5c15
Compare
@LinusU I removed all the ignore comments and refactored git/commit to a way more concise format, causing the tests to fulfill the coverage thresholds. |
// console.log('commit happened'); | ||
}); | ||
|
||
throw new Error('Error: No files added to staging! Did you forget to run git add?'); |
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.
You can remove the Error:
part from the start of the message, the error class will add that when casting to a string.
Can you rebase this on latest master now that your two other pull requests got merged? Remember to remove those commit when rebasing so that they don't get added twice... |
54e5c15
to
d8afcfb
Compare
Rebased master and fixed up all commits, reworded base commit from "chore" to "refactor" type. |
Ping! |
Any news on this? |
Sorry, I've been away celebrating Swedish midsummer 🇸🇪 🌳 🍸 I'll try and look at this shortly |
It doesn't seem like you are removing gulp and gulp-git from the package.json, could you do that? |
Instead of using child_process.exec, would it be better to use |
d8afcfb
to
955eb42
Compare
* gets rid of gulp dependency * gets rid of gulp-git dependency * solves gulp-related deprecation warnings * improves install times considerably * use child_process.exec for git commands
955eb42
to
dbf16d8
Compare
Removed gulp and gulp-git from
|
stagingIsClean = false; | ||
} else { | ||
stagingIsClean = true; | ||
exec('git diff --cached --name-only', { |
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.
Should we keep --no-pager
here?
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.
I think --no-pager
isn't needed here, as the succeeding tests at test/tests/staging show. I guess the option was intended to guard against counting the length of the pager (END)
string. According to my tests git diff
output is not paged anyway in non-tty processes.
Fair enough 👌 One last question but otherwise I'm okay on landing this. @jimthedev any feelings on this? |
I've been listening and at this point I'm ok with landing this. You've Otherwise I'm totally on board with removing these. On June 29, 2016 at 12:52:42 AM, Linus Unnebäck ([email protected])
|
Concerning Changes
Important unchanged stuff
So there are changes that could break stuff for people relying on
Given the fact there was no other way for cli consumers to tell success from error except checking for output on I could add a Breaking Change notice to the commit body if you are on the same page. |
Major version bump for these changes? |
Any news? |
Sorry again for delays. I would prefer not to make a major bump since I don't see that this would have an impact on current users... I have a really hard time imagining that changing the error output would be a problem, unless someone is doing exact string comparison on errors which seems unlikely. Someone could potentially be relaying on the exit code always being I'm okay with merging this now and releasing as a patch release. @jimthedev should have final say though, if you just give the go ahead I will happily merge and cut a new release 👌 |
Hey @LinusU @jimthedev, can we go forward on this? |
I am on board with @LinusU's plan. |
Great, thank you for your work @marionebl! |
commit
andlog