checkout: introduce git_checkout_index()

This commit is contained in:
nulltoken
2012-09-17 10:48:27 +02:00
parent 3aa443a951
commit e93af30411
2 changed files with 55 additions and 19 deletions
+14
View File
@@ -70,6 +70,20 @@ GIT_EXTERN(int) git_checkout_reference(
git_checkout_opts *opts,
git_indexer_stats *stats);
/**
* Updates files in the working tree to match the content of the index.
*
* @param repo repository to check out (must be non-bare)
* @param opts specifies checkout options (may be NULL)
* @param stats structure through which progress information is reported
* @return 0 on success, GIT_ERROR otherwise (use giterr_last for information
* about the error)
*/
GIT_EXTERN(int) git_checkout_index(
git_repository *repo,
git_checkout_opts *opts,
git_indexer_stats *stats);
/**
* Updates files in the index and working tree to match the content of the
* tree pointed at by the treeish.