{
    "mode": "man",
    "parameter": "git-fmt-merge-msg",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/git-fmt-merge-msg/1/json",
    "generated": "2026-06-17T13:37:42Z",
    "synopsis": "git fmt-merge-msg [-m <message>] [--log[=<n>] | --no-log]\ngit fmt-merge-msg [-m <message>] [--log[=<n>] | --no-log] -F <file>",
    "sections": {
        "NAME": {
            "content": "git-fmt-merge-msg - Produce a merge commit message\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "git fmt-merge-msg [-m <message>] [--log[=<n>] | --no-log]\ngit fmt-merge-msg [-m <message>] [--log[=<n>] | --no-log] -F <file>\n\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Takes the list of merged objects on stdin and produces a suitable commit message to be used\nfor the merge commit, usually to be passed as the <merge-message> argument of git merge.\n\nThis command is intended mostly for internal use by scripts automatically invoking git merge.\n",
            "subsections": []
        },
        "OPTIONS": {
            "content": "--log[=<n>]\nIn addition to branch names, populate the log message with one-line descriptions from the\nactual commits that are being merged. At most <n> commits from each merge parent will be\nused (20 if <n> is omitted). This overrides the merge.log configuration variable.\n",
            "subsections": [
                {
                    "name": "--no-log",
                    "content": "Do not list one-line descriptions from the actual commits being merged.\n\n--[no-]summary\nSynonyms to --log and --no-log; these are deprecated and will be removed in the future.\n",
                    "long": "--no-log"
                },
                {
                    "name": "-m <message>, --message <message>",
                    "content": "Use <message> instead of the branch names for the first line of the log message. For use\nwith --log.\n",
                    "flag": "-m",
                    "long": "--message",
                    "arg": "<message>"
                },
                {
                    "name": "-F <file>, --file <file>",
                    "content": "Take the list of merged objects from <file> instead of stdin.\n",
                    "flag": "-F",
                    "long": "--file",
                    "arg": "<file>"
                }
            ]
        },
        "CONFIGURATION": {
            "content": "merge.branchdesc\nIn addition to branch names, populate the log message with the branch description text\nassociated with them. Defaults to false.\n\nmerge.log\nIn addition to branch names, populate the log message with at most the specified number\nof one-line descriptions from the actual commits that are being merged. Defaults to\nfalse, and true is a synonym for 20.\n\nmerge.suppressDest\nBy adding a glob that matches the names of integration branches to this multi-valued\nconfiguration variable, the default merge message computed for merges into these\nintegration branches will omit \"into <branch name>\" from its title.\n\nAn element with an empty value can be used to clear the list of globs accumulated from\nprevious configuration entries. When there is no merge.suppressDest variable defined, the\ndefault value of master is used for backward compatibility.\n\nmerge.summary\nSynonym to merge.log; this is deprecated and will be removed in the future.\n",
            "subsections": []
        },
        "EXAMPLES": {
            "content": "$ git fetch origin master\n$ git fmt-merge-msg --log <$GITDIR/FETCHHEAD\n\n\nPrint a log message describing a merge of the \"master\" branch from the \"origin\" remote.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "git-merge(1)\n",
            "subsections": []
        },
        "GIT": {
            "content": "Part of the git(1) suite\n\n\n\nGit 2.34.1                                   02/26/2026                         GIT-FMT-MERGE-MSG(1)",
            "subsections": []
        }
    },
    "summary": "git-fmt-merge-msg - Produce a merge commit message",
    "flags": [
        {
            "flag": "",
            "long": "--no-log",
            "arg": null,
            "description": "Do not list one-line descriptions from the actual commits being merged. --[no-]summary Synonyms to --log and --no-log; these are deprecated and will be removed in the future."
        },
        {
            "flag": "-m",
            "long": "--message",
            "arg": "<message>",
            "description": "Use <message> instead of the branch names for the first line of the log message. For use with --log."
        },
        {
            "flag": "-F",
            "long": "--file",
            "arg": "<file>",
            "description": "Take the list of merged objects from <file> instead of stdin."
        }
    ],
    "examples": [
        "$ git fetch origin master",
        "$ git fmt-merge-msg --log <$GITDIR/FETCHHEAD",
        "Print a log message describing a merge of the \"master\" branch from the \"origin\" remote."
    ],
    "see_also": [
        {
            "name": "git-merge",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/git-merge/1/json"
        }
    ]
}