macgitver/MacGitverModules — pull request #63 by antis81 (2013-05-01 07:25:54+00:00)
Title: unstage files

Unstaging of untracked files, which are new to the index is a simple `index.remove();`. This will mark the file as untracked.

To unstage modified files, we need to set the mode in `IndexEntry` and after that update the index by `addEntry(modifiedEntry)`. Here the copied struct hurts of course, because we need to convert it to a `git_index_entry` (maybe with something like `indexEntry.toRawEntry()`). Any ideas how to do it right?