Use a common function to get the pretty name of refs
[gitweb.git] / builtin-send-pack.c
index 9072905f10cbbb0f8297bc1b1c7dfb12613c80a7..43b89ece36ed0a50f2fb298c0159f08ffa5f8700 100644 (file)
@@ -172,16 +172,6 @@ static void update_tracking_ref(struct remote *remote, struct ref *ref)
        }
 }
 
-static const char *prettify_ref(const struct ref *ref)
-{
-       const char *name = ref->name;
-       return name + (
-               !prefixcmp(name, "refs/heads/") ? 11 :
-               !prefixcmp(name, "refs/tags/") ? 10 :
-               !prefixcmp(name, "refs/remotes/") ? 13 :
-               0);
-}
-
 #define SUMMARY_WIDTH (2 * DEFAULT_ABBREV + 3)
 
 static void print_ref_status(char flag, const char *summary, struct ref *to, struct ref *from, const char *msg)