diff options
author | David Turner <dturner@twopensource.com> | 2016-09-04 18:08:42 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-09-09 15:28:14 -0700 |
commit | 9b6b40d93a4c93d36225533ddc6717841b07d09d (patch) | |
tree | 418354561ebaec06aeaecaca2105446767153fbd /refs.c | |
parent | 6fb5acfd8f7102f53dedc887233313f233a65932 (diff) | |
download | git-9b6b40d93a4c93d36225533ddc6717841b07d09d.tar.gz |
refs: add method to rename refs
This removes the last caller of function get_files_ref_store(), so
remove it.
Signed-off-by: David Turner <dturner@twopensource.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs.c')
-rw-r--r-- | refs.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -1547,3 +1547,10 @@ int delete_refs(struct string_list *refnames, unsigned int flags) return refs->be->delete_refs(refs, refnames, flags); } + +int rename_ref(const char *oldref, const char *newref, const char *logmsg) +{ + struct ref_store *refs = get_ref_store(NULL); + + return refs->be->rename_ref(refs, oldref, newref, logmsg); +} |