taskolib / libgit4cpp

C++ wrapper for libgit2 with limited functionality
https://taskolib.github.io/libgit4cpp/
GNU Lesser General Public License v2.1
1 stars 0 forks source link

Improve doc and test on remove_*() #11

Closed Finii closed 7 months ago

Finii commented 7 months ago

[why] People might wonder if remove_files() does remove the files just from the index or also from the filesystem.

The command-line git rm fasel.cc does remove the file; so that might be expected. But the GitRepository functions just manipulate the index and leave the real files in existence (or absense).

The user has more freedom to manipulate the index in this way, for example a subdirectory can be removed from the index (but still exists locally), that change is commited and pushed to the remote repo and only on fetch the local repository shows the centrally managed state.

[how] Leave implmentation as it is. Add tests and documentation.


Note: The test has been described in the comment in the tests, but not been coded.

Finii commented 7 months ago

Thanks for the review!