1. 19 Jun, 2013 2 commits
    • Add tests and fix use of freed memory · 7863523a
      This adds some tests for updating the index and having it remove
      items to make sure that the iteration over the index still works
      even as earlier items are removed.
      
      In testing with valgrind, this found a path that would use the
      path string from the index entry after it had been freed.  The
      bug fix is simply to copy the path of the index entry before
      doing any actual index manipulation.
      Russell Belfer committed
    • Add index pathspec-based operations · f30fff45
      This adds three new public APIs for manipulating the index:
      
      1. `git_index_add_all` is similar to `git add -A` and will add
         files in the working directory that match a pathspec to the
         index while honoring ignores, etc.
      2. `git_index_remove_all` removes files from the index that match
         a pathspec.
      3. `git_index_update_all` updates entries in the index based on
         the current contents of the working directory, either added
         the new information or removing the entry from the index.
      Russell Belfer committed