{"thread":{"id":"50681","subject":"worth mentioning branch \"mergeOptions\" from \"man git-merge\"?","startedAt":"2019-03-07T13:31:49Z","lastAt":"2019-03-07T13:31:49Z","messageCount":1,"participants":["Robert P. J. Day"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"370904","messageId":"alpine.LFD.2.21.1903070825230.8072@localhost.localdomain","threadId":"50681","inReplyTo":null,"subject":"worth mentioning branch \"mergeOptions\" from \"man git-merge\"?","fromName":"Robert P. J. Day","fromEmail":"rpjday@crashcourse.ca","sentAt":"2019-03-07T13:31:43Z","receivedAt":"2019-03-07T13:31:49Z","isPatch":false,"sender":{"key":"rpjday@crashcourse.ca","avatar":"https://avatars.githubusercontent.com/u/226084077?v=4"},"body":"\n  reading, in various places, people asking how to globally set\noptions for merging, to which the standard answer is, no, you can't do\nthat *globally*, but you can do it on a per-branch basis with\n\n  branch.<branchname>.mergeOptions\n\nthe most common example being to squash into master:\n\n  git config branch.master.mergeOptions \"--squash\"\n\nhowever, i read in \"man git-config\":\n\nmerge.ff\n    By default, Git does not create an extra merge commit when\n    merging a commit that is a descendant of the current\n    commit. Instead, the tip of the current branch is\n    fast-forwarded. When set to false, this variable tells Git\n    to create an extra merge commit in such a case (equivalent\n    to giving the --no-ff option from the command line). When\n    set to only, only such fast-forward merges are allowed\n    (equivalent to giving the --ff-only option from the command\n    line).\n\nwhere (based on a quick test i tried and, hopefully, did not screw\nup), the per-branch mergeOptions value for fast-forwarding takes\nprecedence over the global merge.ff value.\n\n  this is the only merge option i've noticed that has a global\nsettings as well as per-branch setting. is it worth putting in an\nextra line or two mentioning this in the man page? that is, as long as\ni've understood this correctly.\n\nrday\n\n-- \n\n========================================================================\nRobert P. J. Day                                 Ottawa, Ontario, CANADA\n                  http://crashcourse.ca/dokuwiki\n\nTwitter:                                       http://twitter.com/rpjday\nLinkedIn:                               http://ca.linkedin.com/in/rpjday\n========================================================================\n"}]}