This commit is contained in:
di-sukharev
2023-05-20 18:08:08 +08:00
parent 3b32ef3608
commit 542a53f3db
2 changed files with 4 additions and 22 deletions

View File

@@ -28002,21 +28002,12 @@ async function improveCommitMessagesWithRebase({
"rebase",
"-i",
`origin/${base}`,
"--exec",
"git",
"commit",
"--amend",
"--no-edit",
"-F",
tempFilePath
`"--exec git commit --amend --no-edit -F ${tempFilePath}"`
]);
(0, import_fs2.unlinkSync)(tempFilePath);
ce("Commit improved \u{1F31E}");
} catch (error) {
throw error;
} finally {
ce(
"\u{1F4DD} Commit messages improved with an interactive rebase: `$ rebase -i`"
);
}
}
ce("Force pushing interactively rebased commits into remote origin.");

View File

@@ -154,25 +154,16 @@ async function improveCommitMessagesWithRebase({
'rebase',
'-i',
`origin/${base}`,
'--exec',
'git',
'commit',
'--amend',
'--no-edit',
'-F',
tempFilePath
`"--exec git commit --amend --no-edit -F ${tempFilePath}"`
]);
unlinkSync(tempFilePath);
outro('Commit improved 🌞');
// await execa('git', ['commit', '--amend', '-m', improvedMessage]);
// await execa('git', ['rebase', '--continue']);
} catch (error) {
throw error;
} finally {
outro(
'📝 Commit messages improved with an interactive rebase: `$ rebase -i`'
);
}
}