MCPcopy Index your code
hub / github.com/git/git / drop_prefix

Function drop_prefix

help.c:59–78  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57};
58
59static const char *drop_prefix(const char *name, uint32_t category)
60{
61 const char *new_name;
62 const char *prefix;
63
64 switch (category) {
65 case CAT_guide:
66 case CAT_userinterfaces:
67 case CAT_developerinterfaces:
68 prefix = "git";
69 break;
70 default:
71 prefix = "git-";
72 break;
73 }
74 if (skip_prefix(name, prefix, &new_name))
75 return new_name;
76
77 return name;
78}
79
80static void extract_cmds(struct cmdname_help **p_cmds, uint32_t mask)
81{

Callers 2

extract_cmdsFunction · 0.85
list_cmds_by_categoryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected