Skip to content

Commit 2171c0c

Browse files
committed
Merge branch 'tb/repack-fix-renames' (early part)
Finishing touches to the "rewrite repack in C" series. * 'tb/repack-fix-renames' (early part): repack.c: rename and unlink pack file if it exists
2 parents be961c2 + 9d7fbfd commit 2171c0c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

builtin/repack.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ int cmd_repack(int argc, const char **argv, const char *prefix)
258258
for_each_string_list_item(item, &names) {
259259
for (ext = 0; ext < 2; ext++) {
260260
char *fname, *fname_old;
261-
fname = mkpathdup("%s/%s%s", packdir,
261+
fname = mkpathdup("%s/pack-%s%s", packdir,
262262
item->string, exts[ext]);
263263
if (!file_exists(fname)) {
264264
free(fname);
@@ -335,7 +335,7 @@ int cmd_repack(int argc, const char **argv, const char *prefix)
335335
for_each_string_list_item(item, &names) {
336336
for (ext = 0; ext < 2; ext++) {
337337
char *fname;
338-
fname = mkpath("%s/old-pack-%s%s",
338+
fname = mkpath("%s/old-%s%s",
339339
packdir,
340340
item->string,
341341
exts[ext]);

0 commit comments

Comments
 (0)