镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

How can I stage lines and hunks? #71

Open

Description

@demian85

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.

Activity

  1. samcday commented on Feb 17, 2014

    @samcday
    Contributor

    @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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions