Skip to content

Commit dc2a073

Browse files
committed
Merge branch 'ab/remove-rebase-usebuiltin'
Remove the final hint that we used to have a scripted "git rebase". * ab/remove-rebase-usebuiltin: rebase: remove transitory rebase.useBuiltin setting & env
2 parents 5013802 + 9bcde4d commit dc2a073

File tree

3 files changed

+0
-34
lines changed

3 files changed

+0
-34
lines changed

Documentation/config/rebase.txt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,3 @@
1-
rebase.useBuiltin::
2-
Unused configuration variable. Used in Git versions 2.20 and
3-
2.21 as an escape hatch to enable the legacy shellscript
4-
implementation of rebase. Now the built-in rewrite of it in C
5-
is always used. Setting this will emit a warning, to alert any
6-
remaining users that setting this now does nothing.
7-
81
rebase.backend::
92
Default backend to use for rebasing. Possible choices are
103
'apply' or 'merge'. In the future, if the merge backend gains

builtin/rebase.c

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ struct rebase_options {
100100
char *strategy, *strategy_opts;
101101
struct strbuf git_format_patch_opt;
102102
int reschedule_failed_exec;
103-
int use_legacy_rebase;
104103
int reapply_cherry_picks;
105104
int fork_point;
106105
};
@@ -1102,11 +1101,6 @@ static int rebase_config(const char *var, const char *value, void *data)
11021101
return 0;
11031102
}
11041103

1105-
if (!strcmp(var, "rebase.usebuiltin")) {
1106-
opts->use_legacy_rebase = !git_config_bool(var, value);
1107-
return 0;
1108-
}
1109-
11101104
if (!strcmp(var, "rebase.backend")) {
11111105
return git_config_string(&opts->default_backend, var, value);
11121106
}
@@ -1441,11 +1435,6 @@ int cmd_rebase(int argc, const char **argv, const char *prefix)
14411435
gpg_sign = options.gpg_sign_opt ? "" : NULL;
14421436
FREE_AND_NULL(options.gpg_sign_opt);
14431437

1444-
if (options.use_legacy_rebase ||
1445-
!git_env_bool("GIT_TEST_REBASE_USE_BUILTIN", -1))
1446-
warning(_("the rebase.useBuiltin support has been removed!\n"
1447-
"See its entry in 'git help config' for details."));
1448-
14491438
strbuf_reset(&buf);
14501439
strbuf_addf(&buf, "%s/applying", apply_dir());
14511440
if(file_exists(buf.buf))

t/t3400-rebase.sh

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -388,22 +388,6 @@ test_expect_success 'rebase--merge.sh and --show-current-patch' '
388388
)
389389
'
390390

391-
test_expect_success 'rebase -c rebase.useBuiltin=false warning' '
392-
expected="rebase.useBuiltin support has been removed" &&
393-
394-
# Only warn when the legacy rebase is requested...
395-
test_must_fail git -c rebase.useBuiltin=false rebase 2>err &&
396-
test_i18ngrep "$expected" err &&
397-
test_must_fail env GIT_TEST_REBASE_USE_BUILTIN=false git rebase 2>err &&
398-
test_i18ngrep "$expected" err &&
399-
400-
# ...not when we would have used the built-in anyway
401-
test_must_fail git -c rebase.useBuiltin=true rebase 2>err &&
402-
test_must_be_empty err &&
403-
test_must_fail env GIT_TEST_REBASE_USE_BUILTIN=true git rebase 2>err &&
404-
test_must_be_empty err
405-
'
406-
407391
test_expect_success 'switch to branch checked out here' '
408392
git checkout main &&
409393
git rebase main main

0 commit comments

Comments
 (0)