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

How can I stage lines and hunks? #71

Open
demian85 opened this issue Feb 13, 2014 · 1 comment
Open

How can I stage lines and hunks? #71

demian85 opened this issue Feb 13, 2014 · 1 comment

Comments

@demian85
Copy link

Hi,

I've been working on a 'git-gui' desktop app. I invite you to take a look: https://github.com/demian85/git-watcher

All the current functionality is provided by native git commands and the git-utils module.

Now, to make it more useful, I would like to implement at least the following features:

  • Amend commit: I need to show files from previous commit and allow to stage them in a 'sandbox' to avoid modifying the current repository.
  • Stage by lines and hunks: The same as git-gui.

I've done a bit of research and my conclusion is that there is no way to implement those features without using a native git API.

Can node-gitteh help me? I couldn't find a clue by looking at the old documentation.

Thanks for your help.

@samcday
Copy link
Contributor

samcday commented Feb 17, 2014

@demian85 amending commits is definitely something gitteh can do. Staging changes in the index is something that is available in libgit2, but hasn't been handled in these bindings. The diff / staging methods in libgit2 are what you're after specifically. This lib is fairly inactive at the moment (pending a contributor - hint hint :D), you might want to see if nodegit has made available the functionality you're after in Node.

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

2 participants