diff options
author | nulltoken <emeric.fermas@gmail.com> | 2012-09-26 19:15:11 +0200 |
---|---|---|
committer | nulltoken <emeric.fermas@gmail.com> | 2012-10-08 00:44:13 +0200 |
commit | 3e012fca770944211bd2b32632f64ae07c42e25d (patch) | |
tree | 885469efb1434c995292c43670db4b7f5dc2d698 /src/refspec.h | |
parent | 70edc1b0fc98c22e6c0f73c7292cb858e444e5c2 (diff) | |
download | libgit2-3e012fca770944211bd2b32632f64ae07c42e25d.tar.gz |
refspec: introduce git_refspec_transform_l()
Diffstat (limited to 'src/refspec.h')
-rw-r--r-- | src/refspec.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/refspec.h b/src/refspec.h index a5df458c6..6e0596a55 100644 --- a/src/refspec.h +++ b/src/refspec.h @@ -40,4 +40,15 @@ void git_refspec__free(git_refspec *refspec); */ int git_refspec_transform_r(git_buf *out, const git_refspec *spec, const char *name); +/** + * Transform a reference from its target following the refspec's rules, + * and writes the results into a git_buf. + * + * @param out where to store the source name + * @param spec the refspec + * @param name the name of the reference to transform + * @return 0 or error if buffer allocation fails + */ +int git_refspec_transform_l(git_buf *out, const git_refspec *spec, const char *name); + #endif |