Skip to content
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

if diff has no patches. diff.patch return GitError #232

Closed
alexband opened this issue May 13, 2013 · 5 comments
Closed

if diff has no patches. diff.patch return GitError #232

alexband opened this issue May 13, 2013 · 5 comments

Comments

@alexband
Copy link

if I got a Diff, but there is not patches

so

[patch  for patch in diff] is []

then call diff.patch will raise GitError

might it return empty string '' ?

@cholin
Copy link

cholin commented May 20, 2013

I think the empty string is not a valid input for the unix tool patch (which is the output format of Diff.patch), so I don't think this would be a general benefit for everyone or am I missing here something?

@jleclanche
Copy link

Yeah this is pretty annoying. Simple way to test:

repo.diff("HEAD", "HEAD").patch

@xtao
Copy link
Contributor

xtao commented Dec 16, 2013

#303

@xtao
Copy link
Contributor

xtao commented Dec 16, 2013

@alexband fixed in #303

@alexband
Copy link
Author

@xtao bien, gracias

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants