diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-12-27 14:57:50 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-12-27 14:57:50 -0800 |
commit | 7cdebd8a2039cb3ec717b880709ea6dfd824e3c4 (patch) | |
tree | f07fff24eb335bc59849625af60378a869f766a8 /remote.h | |
parent | 7794a680e63a2a11b73cb1194653662f2769a792 (diff) | |
parent | fc9261ca611080b1dae76b86b3bf5f36d592042f (diff) | |
download | git-7cdebd8a2039cb3ec717b880709ea6dfd824e3c4.tar.gz |
Merge branch 'jc/push-refmap'
Make "git push origin master" update the same ref that would be
updated by our 'master' when "git push origin" (no refspecs) is run
while the 'master' branch is checked out, which makes "git push"
more symmetric to "git fetch" and more usable for the triangular
workflow.
* jc/push-refmap:
push: also use "upstream" mapping when pushing a single ref
push: use remote.$name.push as a refmap
builtin/push.c: use strbuf instead of manual allocation
Diffstat (limited to 'remote.h')
-rw-r--r-- | remote.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -128,6 +128,7 @@ struct ref *alloc_ref(const char *name); struct ref *copy_ref(const struct ref *ref); struct ref *copy_ref_list(const struct ref *ref); void sort_ref_list(struct ref **, int (*cmp)(const void *, const void *)); +extern int count_refspec_match(const char *, struct ref *refs, struct ref **matched_ref); int ref_compare_name(const void *, const void *); int check_ref_type(const struct ref *ref, int flags); @@ -162,6 +163,7 @@ struct refspec *parse_fetch_refspec(int nr_refspec, const char **refspec); void free_refspec(int nr_refspec, struct refspec *refspec); +extern int query_refspecs(struct refspec *specs, int nr, struct refspec *query); char *apply_refspecs(struct refspec *refspecs, int nr_refspec, const char *name); |