Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
trace2:data: add subverb to reset command
author
Jeff Hostetler
<jeffhost@microsoft.com>
Fri, 22 Feb 2019 22:25:09 +0000
(14:25 -0800)
committer
Junio C Hamano
<gitster@pobox.com>
Fri, 22 Feb 2019 23:28:21 +0000
(15:28 -0800)
Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/reset.c
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
e27dd8a
)
diff --git
a/builtin/reset.c
b/builtin/reset.c
index 4d18a461fab631dd752adec3b95197a3a2657a62..7882829a95d8294ea5bb5bcba3335e651233d79a 100644
(file)
--- a/
builtin/reset.c
+++ b/
builtin/reset.c
@@
-341,6
+341,7
@@
int cmd_reset(int argc, const char **argv, const char *prefix)
if (patch_mode) {
if (reset_type != NONE)
die(_("--patch is incompatible with --{hard,mixed,soft}"));
if (patch_mode) {
if (reset_type != NONE)
die(_("--patch is incompatible with --{hard,mixed,soft}"));
+ trace2_cmd_mode("patch-interactive");
return run_add_interactive(rev, "--patch=reset", &pathspec);
}
return run_add_interactive(rev, "--patch=reset", &pathspec);
}
@@
-357,6
+358,11
@@
int cmd_reset(int argc, const char **argv, const char *prefix)
if (reset_type == NONE)
reset_type = MIXED; /* by default */
if (reset_type == NONE)
reset_type = MIXED; /* by default */
+ if (pathspec.nr)
+ trace2_cmd_mode("path");
+ else
+ trace2_cmd_mode(reset_type_names[reset_type]);
+
if (reset_type != SOFT && (reset_type != MIXED || get_git_work_tree()))
setup_work_tree();
if (reset_type != SOFT && (reset_type != MIXED || get_git_work_tree()))
setup_work_tree();