Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 1 | git-fmt-merge-msg(1) |
| 2 | ==================== |
| 3 | |
| 4 | NAME |
| 5 | ---- |
| 6 | git-fmt-merge-msg - Produce a merge commit message |
| 7 | |
| 8 | |
| 9 | SYNOPSIS |
| 10 | -------- |
Junio C Hamano | a9b8d24 | 2007-05-19 04:51:55 | [diff] [blame] | 11 | [verse] |
Junio C Hamano | e872a1c | 2022-01-05 22:15:13 | [diff] [blame] | 12 | 'git fmt-merge-msg' [-m <message>] [--into-name <branch>] [--log[=<n>] | --no-log] |
Junio C Hamano | 3b4609d | 2010-09-30 00:04:34 | [diff] [blame] | 13 | 'git fmt-merge-msg' [-m <message>] [--log[=<n>] | --no-log] -F <file> |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 14 | |
| 15 | DESCRIPTION |
| 16 | ----------- |
| 17 | Takes the list of merged objects on stdin and produces a suitable |
| 18 | commit message to be used for the merge commit, usually to be |
Junio C Hamano | 1aa40d2 | 2010-01-21 17:46:43 | [diff] [blame] | 19 | passed as the '<merge-message>' argument of 'git merge'. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 20 | |
Junio C Hamano | c0e55e7 | 2009-10-10 00:56:29 | [diff] [blame] | 21 | This command is intended mostly for internal use by scripts |
| 22 | automatically invoking 'git merge'. |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 23 | |
Junio C Hamano | 9882a52 | 2007-04-27 08:22:22 | [diff] [blame] | 24 | OPTIONS |
| 25 | ------- |
| 26 | |
Junio C Hamano | 3b4609d | 2010-09-30 00:04:34 | [diff] [blame] | 27 | --log[=<n>]:: |
Junio C Hamano | 9882a52 | 2007-04-27 08:22:22 | [diff] [blame] | 28 | In addition to branch names, populate the log message with |
| 29 | one-line descriptions from the actual commits that are being |
Junio C Hamano | 3b4609d | 2010-09-30 00:04:34 | [diff] [blame] | 30 | merged. At most <n> commits from each merge parent will be |
| 31 | used (20 if <n> is omitted). This overrides the `merge.log` |
| 32 | configuration variable. |
Junio C Hamano | 9882a52 | 2007-04-27 08:22:22 | [diff] [blame] | 33 | |
Junio C Hamano | 6d76d61 | 2008-05-09 05:46:08 | [diff] [blame] | 34 | --no-log:: |
Junio C Hamano | 9882a52 | 2007-04-27 08:22:22 | [diff] [blame] | 35 | Do not list one-line descriptions from the actual commits being |
| 36 | merged. |
| 37 | |
Junio C Hamano | 3d1b5a1 | 2013-05-17 23:34:02 | [diff] [blame] | 38 | --[no-]summary:: |
Junio C Hamano | 6d76d61 | 2008-05-09 05:46:08 | [diff] [blame] | 39 | Synonyms to --log and --no-log; these are deprecated and will be |
| 40 | removed in the future. |
| 41 | |
Junio C Hamano | 2db3e75 | 2010-09-03 21:33:06 | [diff] [blame] | 42 | -m <message>:: |
| 43 | --message <message>:: |
| 44 | Use <message> instead of the branch names for the first line |
| 45 | of the log message. For use with `--log`. |
| 46 | |
Junio C Hamano | e872a1c | 2022-01-05 22:15:13 | [diff] [blame] | 47 | --into-name <branch>:: |
| 48 | Prepare the merge message as if merging to the branch `<branch>`, |
| 49 | instead of the name of the real branch to which the merge is made. |
| 50 | |
Junio C Hamano | eb41599 | 2008-06-08 22:49:47 | [diff] [blame] | 51 | -F <file>:: |
| 52 | --file <file>:: |
Junio C Hamano | 9882a52 | 2007-04-27 08:22:22 | [diff] [blame] | 53 | Take the list of merged objects from <file> instead of |
| 54 | stdin. |
| 55 | |
| 56 | CONFIGURATION |
| 57 | ------------- |
Junio C Hamano | 06ce83b | 2018-11-13 14:06:12 | [diff] [blame] | 58 | include::config/fmt-merge-msg.txt[] |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 59 | |
Junio C Hamano | 6d76d61 | 2008-05-09 05:46:08 | [diff] [blame] | 60 | merge.summary:: |
| 61 | Synonym to `merge.log`; this is deprecated and will be removed in |
| 62 | the future. |
| 63 | |
Junio C Hamano | b9d9d90 | 2018-05-23 07:07:42 | [diff] [blame] | 64 | EXAMPLES |
| 65 | -------- |
Junio C Hamano | daf0aae | 2015-10-26 23:14:30 | [diff] [blame] | 66 | |
Junio C Hamano | f2f28b1 | 2016-10-31 21:41:58 | [diff] [blame] | 67 | --------- |
Junio C Hamano | daf0aae | 2015-10-26 23:14:30 | [diff] [blame] | 68 | $ git fetch origin master |
| 69 | $ git fmt-merge-msg --log <$GIT_DIR/FETCH_HEAD |
Junio C Hamano | f2f28b1 | 2016-10-31 21:41:58 | [diff] [blame] | 70 | --------- |
Junio C Hamano | daf0aae | 2015-10-26 23:14:30 | [diff] [blame] | 71 | |
| 72 | Print a log message describing a merge of the "master" branch from |
| 73 | the "origin" remote. |
| 74 | |
| 75 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 76 | SEE ALSO |
| 77 | -------- |
Junio C Hamano | 35738e8 | 2008-01-07 07:55:46 | [diff] [blame] | 78 | linkgit:git-merge[1] |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 79 | |
Junio C Hamano | 1a4e841 | 2005-12-27 08:17:23 | [diff] [blame] | 80 | GIT |
| 81 | --- |
Junio C Hamano | f7c042d | 2008-06-06 22:50:53 | [diff] [blame] | 82 | Part of the linkgit:git[1] suite |