Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/backport.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,12 @@ const getFailedBackportCommentBody = ({
`git worktree remove ${worktreePath}`,
"```",
`Then, create a pull request where the \`base\` branch is \`${base}\` and the \`compare\`/\`head\` branch is \`${head}\`.`,
"The same operations in one line (use carefully)",
"```bash",
`git fetch && git worktree add ${worktreePath} ${base} && pushd ${worktreePath} && git switch --create ${head} && git cherry-pick -x --mainline 1 ${commitSha} && git mergetool`,
"# ... and after fixing all conflicts",
`git cherry-pick --continue && git push --set-upstream origin ${head} && popd && git worktree remove ${worktreePath}`,
"```"
].join("\n");
};

Expand Down