strip suffix .git used typically for bare repos
This commit is contained in:
parent
3da41fa5dd
commit
e4e03b3bf9
3
urmoms.c
3
urmoms.c
|
@ -791,6 +791,9 @@ main(int argc, char *argv[])
|
||||||
p = xbasename(repodir);
|
p = xbasename(repodir);
|
||||||
snprintf(name, sizeof(name), "%s", p);
|
snprintf(name, sizeof(name), "%s", p);
|
||||||
free(p);
|
free(p);
|
||||||
|
/* remove .git suffix, typically used by bare repos */
|
||||||
|
if ((p = strstr(name, ".git")))
|
||||||
|
*p = '\0';
|
||||||
|
|
||||||
/* read description or .git/description */
|
/* read description or .git/description */
|
||||||
snprintf(path, sizeof(path), "%s%s%s",
|
snprintf(path, sizeof(path), "%s%s%s",
|
||||||
|
|
Loading…
Reference in a new issue