Home > Software design >  Using GitHub website for non-fast-forward merging of PRs, instead of Git CLI
Using GitHub website for non-fast-forward merging of PRs, instead of Git CLI

Time:09-30

I'm wondering if there is an equivalent to performing the following to do a non-fast-forward merge into the current branch for preserving my branch topology:

git merge --no-ff <some-branch>

...without using the git CLI or desktop apps, purely within the GitHub web interface?

How does one perform this for PRs made on the web interface?

Any pointers or clarifications would be much appreciated.

CodePudding user response:

You can just use Github Pull Request do this! It use --no-ff by default if you didn't change config.

The following text is from Github docs:

When you click the default Merge pull request option on a pull request on GitHub, all commits from the feature branch are added to the base branch in a merge commit. The pull request is merged using the --no-ff option.

If you want to always merge branch with --no-ff, you can disable other merge method (squash and rebase) in your repo setting. See this docs about squashing merge and configure it.

  • Related