rebase: add --reset-author-date
The previous commit introduced --ignore-date flag to interactive rebase, but the name is actually very vague in context of rebase -i since there are two dates we can work with. Add an alias to convey the precise purpose. Signed-off-by: Rohit Ashiwal <rohit.ashiwal265@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Rohit Ashiwal committed
Nov 1, 2019 at 19:30 UTC
fe28ad8520a0ecac5dfcbfa019727aa6d79c36dc
2 files changed
+3
Documentation/git-rebase.txt
+1
@@ -391,6 +391,7 @@ See also INCOMPATIBLE OPTIONS below.
391
as the committer date. This implies --force-rebase.
392
393
--ignore-date::
394
+--reset-author-date::
395
Instead of using the given author date, reset it to the
396
current time. This implies --force-rebase.
397
+
builtin/rebase.c
+2
@@ -1436,6 +1436,8 @@ int cmd_rebase(int argc, const char **argv, const char *prefix)
1436
OPT_BOOL(0, "committer-date-is-author-date",
1437
&options.committer_date_is_author_date,
1438
N_("make committer date match author date")),
1439
+ OPT_BOOL(0, "reset-author-date", &options.ignore_date,
1440
+ "ignore author date and use current date"),
1441
OPT_BOOL(0, "ignore-date", &options.ignore_date,
1442
"ignore author date and use current date"),
1443
OPT_PASSTHRU_ARGV('C', NULL, &options.git_am_opts, N_("n"),