diff options
author | Ben Straub <bstraub@github.com> | 2012-07-26 13:12:21 -0700 |
---|---|---|
committer | Ben Straub <bstraub@github.com> | 2012-07-26 13:12:21 -0700 |
commit | b401bace1b28ac23990382605791eddbeda09d9b (patch) | |
tree | c6611b78a99a3fdcbac9084deac2ab397b6fe639 /include/git2/clone.h | |
parent | ef9905c9902a9ffad71c8acddec74dc0d8e866de (diff) | |
download | libgit2-b401bace1b28ac23990382605791eddbeda09d9b.tar.gz |
Restructure for better checkout options
* Removed the #define for defaults
* Promoted progress structure to top-level API call
argument
Diffstat (limited to 'include/git2/clone.h')
-rw-r--r-- | include/git2/clone.h | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/include/git2/clone.h b/include/git2/clone.h index 5468f09be..73b6ea54c 100644 --- a/include/git2/clone.h +++ b/include/git2/clone.h @@ -10,6 +10,7 @@ #include "common.h" #include "types.h" #include "indexer.h" +#include "checkout.h" /** @@ -27,10 +28,16 @@ GIT_BEGIN_DECL * @param out pointer that will receive the resulting repository object * @param origin_url repository to clone from * @param workdir_path local directory to clone to - * @param stats pointer to structure that receives progress information (may be NULL) + * @param fetch_stats pointer to structure that receives fetch progress information (may be NULL) + * @param checkout_opts options for the checkout step (may be NULL) * @return 0 on success, GIT_ERROR otherwise (use git_error_last for information about the error) */ -GIT_EXTERN(int) git_clone(git_repository **out, const char *origin_url, const char *workdir_path, git_indexer_stats *stats); +GIT_EXTERN(int) git_clone(git_repository **out, + const char *origin_url, + const char *workdir_path, + git_indexer_stats *fetch_stats, + git_indexer_stats *checkout_stats, + git_checkout_opts *checkout_opts); /** * TODO @@ -38,10 +45,13 @@ GIT_EXTERN(int) git_clone(git_repository **out, const char *origin_url, const ch * @param out pointer that will receive the resulting repository object * @param origin_url repository to clone from * @param dest_path local directory to clone to - * @param stats pointer to structure that receives progress information (may be NULL) + * @param fetch_stats pointer to structure that receives fetch progress information (may be NULL) * @return 0 on success, GIT_ERROR otherwise (use git_error_last for information about the error) */ -GIT_EXTERN(int) git_clone_bare(git_repository **out, const char *origin_url, const char *dest_path, git_indexer_stats *stats); +GIT_EXTERN(int) git_clone_bare(git_repository **out, + const char *origin_url, + const char *dest_path, + git_indexer_stats *fetch_stats); /** @} */ GIT_END_DECL |