checkout: update count-checkouts messages
Commit 0f086e6dca [1] counts the number of files updated by "git checkout -- <paths>" command and prints it. Later on 536ec1839d [2] adds the ability to remove files in "git checkout -- <paths>". This is still an update on worktree and should be reported to the user. To prepare for such an update since that commit is on track to 'master' now, the messages are rephrased to avoid "checked out" which does not imply file deletion. [1] 0f086e6dca (checkout: print something when checking out paths - 2018-11-13) [2] 536ec1839d (entry: support CE_WT_REMOVE flag in checkout_entry - 2018-12-20) Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Nguyễn Thái Ngọc Duy committed
Feb 6, 2019 at 09:51 UTC
3c5883b3c96e0435cca2e952754d76c4e45f72e4
1 file changed
+4
-4
builtin/checkout.c
+4
-4
@@ -392,15 +392,15 @@ static int checkout_paths(const struct checkout_opts *opts,
392
393
if (opts->count_checkout_paths) {
394
if (opts->source_tree)
395
- fprintf_ln(stderr, Q_("Checked out %d path out of %s",
396
- "Checked out %d paths out of %s",
395
+ fprintf_ln(stderr, Q_("Updated %d path from %s",
396
+ "Updated %d paths from %s",
397
nr_checkouts),
398
nr_checkouts,
399
find_unique_abbrev(&opts->source_tree->object.oid,
400
DEFAULT_ABBREV));
401
else
402
- fprintf_ln(stderr, Q_("Checked out %d path out of the index",
403
- "Checked out %d paths out of the index",
402
+ fprintf_ln(stderr, Q_("Updated %d path from the index",
403
+ "Updated %d paths from the index",
404
nr_checkouts),
405
nr_checkouts);
406
}