[ 03 ]Commands
copia-cli pr update-branch¶
copia-cli pr update-branch {<number> | <url>} [flags]
Update a pull request branch with the latest changes of the base branch, by number or URL.
The base branch is merged into the head branch with a merge commit. With --rebase the head branch is rebased onto the base branch instead.
A branch that is already up to date is left as it is. A closed or merged pull request cannot be updated.
Options¶
--rebase- Update the pull request branch using the rebase strategy
Options inherited from parent commands¶
--host <string>- Target Copia host
-R,--repo <string>- Select repository (owner/repo)
--token <string>- Authentication token
Examples¶
# Merge the base branch into the branch of pull request 7
$ copia-cli pr update-branch 7
# Rebase the branch onto the base branch
$ copia-cli pr update-branch --rebase \
https://app.copia.io/my-org/my-repo/pulls/7