int is_branch(const char *refname);
+extern int refs_init_db(struct strbuf *err);
+
/*
* If refname is a non-symbolic reference that refers to a tag object,
* and the tag can be (recursively) dereferenced to a non-tag object,
*/
int refname_match(const char *abbrev_name, const char *full_name);
+int expand_ref(const char *str, int len, unsigned char *sha1, char **ref);
int dwim_ref(const char *str, int len, unsigned char *sha1, char **ref);
int dwim_log(const char *str, int len, unsigned char *sha1, char **ref);
* msg -- a message describing the change (for the reflog).
*
* err -- a strbuf for receiving a description of any error that
- * might have occured.
+ * might have occurred.
*
* The functions make internal copies of refname and msg, so the
* caller retains ownership of these parameters.
int update_ref(const char *msg, const char *refname,
const unsigned char *new_sha1, const unsigned char *old_sha1,
unsigned int flags, enum action_on_err onerr);
+int update_ref_oid(const char *msg, const char *refname,
+ const struct object_id *new_oid, const struct object_id *old_oid,
+ unsigned int flags, enum action_on_err onerr);
int parse_hide_refs_config(const char *var, const char *value, const char *);