aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/git-am.txt
AgeCommit message (Collapse)AuthorFilesLines
2024-03-25docs: clean up `--empty` formatting in git-rebase(1) and git-am(1)Brian Lyles1-7/+13
Both of these pages document very similar `--empty` options, but with different styles. The exact behavior of these `--empty` options differs somewhat, but consistent styling in the docs is still beneficial. This commit aims to make them more consistent. Break the possible values for `--empty` into separate sections for readability. Alphabetical order is chosen for consistency. In a future commit, we'll be documenting a new `--empty` option for git-cherry-pick(1), making the consistency even more relevant. Signed-off-by: Brian Lyles <brianmlyles@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2024-02-27Merge branch 'jc/am-whitespace-doc'Junio C Hamano1-0/+3
"git am --help" now tells readers what actions are available in "git am --whitespace=<action>", in addition to saying that the option is passed through to the underlying "git apply". * jc/am-whitespace-doc: doc: add shortcut to "am --whitespace=<action>"
2024-02-14doc: add shortcut to "am --whitespace=<action>"Junio C Hamano1-0/+3
We refer readers of "git am --help" to "git apply --help" for many options that are passed through, and most of them are simple booleans, but --whitespace takes from a set of actions whose names may slip users' minds. Give a list of them in "git am --help" to reduce one level of redirection only to find out what they are. In the helper function to parse the available options, there was a helpful comment reminding the developer to update list of <action>s in the completion script. Mention the two documentation pages there as well. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-11-02Merge branch 'jc/am-doc-whitespace-action-fix' into maint-2.42Junio C Hamano1-2/+2
Docfix. * jc/am-doc-whitespace-action-fix: am: align placeholder for --whitespace option with apply
2023-10-30Merge branch 'jc/am-doc-whitespace-action-fix'Junio C Hamano1-2/+2
Docfix. * jc/am-doc-whitespace-action-fix: am: align placeholder for --whitespace option with apply
2023-10-18am: align placeholder for --whitespace option with applyJunio C Hamano1-2/+2
`git am` passes the value given to its `--whitespace` option through to the underlying `git apply`, and the value is called <action> over there. Fix the documentation for the command that calls the value <option> to say <action> instead. Note that the option help given by `git am -h` already calls the value <action>, so there is no need to make a matching change there. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-10-09documentation: add some commas where they are helpfulElijah Newren1-2/+2
Diff best viewed with --color-diff. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-10-09documentation: use clearer prepositionsElijah Newren1-1/+1
Diff best viewed with --color-diff. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-10-09documentation: add missing articleElijah Newren1-2/+2
Diff best viewed with --color-diff. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-10-09documentation: fix singular vs. pluralElijah Newren1-1/+1
Diff best viewed with --color-diff. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-03-21am: refer to format-patch in the documentationJunio C Hamano1-2/+5
There were two reasons we didn't do this. As "git am" is designed to grok e-mailed patches, not necessarily taken out of a Git repostiory or even if it came from a Git repository not necessarily produced with format-patch, we didn't want to single it out as the "blessed" input producer to the command. Also, in the original workflow that "git am" was invented for, the user of "am" was expected to be a different person than the users of "format-patch". But this is a very safe change to make in 2023. Thanks to the effort by many contributors, Git ended up becoming a bit more popular than we initially thought it would be, and "format-patch", which took me a few weeks to pursuade Linus to take in 2005, seems to have become the de-facto standard tool to produce patch e-mails. Interestingly, the documentation for "git apply", which is listed in SEE ALSO section of "git am" documentation, does mention "am" and "format-patch" as two things that are related but different from "apply" in an early part. Suggested-by: Kai Grossjohann <kai.grossjohann@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-01-05am: allow passing --no-verify flagThierry Reding1-1/+7
The git-am --no-verify flag is analogous to the same flag passed to git-commit. It bypasses the pre-applypatch and applypatch-msg hooks if they are enabled. Signed-off-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2022-09-14Merge branch 'ab/dedup-config-and-command-docs'Junio C Hamano1-0/+7
Share the text used to explain configuration variables used by "git <subcmd>" in "git help <subcmd>" with the text from "git help config". * ab/dedup-config-and-command-docs: docs: add CONFIGURATION sections that fuzzy map to built-ins docs: add CONFIGURATION sections that map to a built-in log docs: de-duplicate configuration sections difftool docs: de-duplicate configuration sections notes docs: de-duplicate and combine configuration sections apply docs: de-duplicate configuration sections send-email docs: de-duplicate configuration sections grep docs: de-duplicate configuration sections docs: add and use include template for config/* includes
2022-09-07docs: add CONFIGURATION sections that map to a built-inÆvar Arnfjörð Bjarmason1-0/+7
Add a CONFIGURATION section to the documentation of various built-ins, for those cases where the relevant config/NAME.txt describes configuration that is only used by the relevant built-in documented in git-NAME.txt. Subsequent commits will handle more complex cases. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Reviewed-by: Matheus Tavares <matheus.bernardino@usp.br> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2022-08-03doc: consolidate --rerere-autoupdate descriptionJunio C Hamano1-4/+1
The `--rerere-autoupdate` option is shared across 5 commands, and are described the same way because it works exactly the same way in these commands. Create a separate file and include it from the help pages for these commands, so that we can improve the description at one place to improve all of them at once, and keep them in sync. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-12-15am: support --allow-empty to record specific empty patches徐沛文 (Aleen)1-1/+6
This option helps to record specific empty patches in the middle of an am session, which does create empty commits only when: 1. the index has not changed 2. lacking a branch When the index has changed, "--allow-empty" will create a non-empty commit like passing "--continue" or "--resolved". Signed-off-by: 徐沛文 (Aleen) <aleen42@vip.qq.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-12-15am: support --empty=<option> to handle empty patches徐沛文 (Aleen)1-0/+9
Since that the command 'git-format-patch' can include patches of commits that emit no changes, the 'git-am' command should also support an option, named as '--empty', to specify how to handle those empty patches. In this commit, we have implemented three valid options ('stop', 'drop' and 'keep'). Signed-off-by: 徐沛文 (Aleen) <aleen42@vip.qq.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-09-10git-am.txt: clarify --abort behaviorElijah Newren1-0/+2
Both Johannes and I assumed (perhaps due to familiarity with rebase) that am --abort would return the user to a clean state. However, since am, unlike rebase, is intended to be used within a dirty working tree, --abort will only clean the files involved in the am operation. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-05-10am: learn to process quoted lines that ends with CRLFĐoàn Trần Công Danh1-0/+4
In previous changes, mailinfo has learnt to process lines that decoded from base64 or quoted-printable, and ends with CRLF. Let's teach "am" that new trick, too. Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2021-02-24i18n.txt: camel case and monospace "i18n.commitEncoding"Denton Liu1-1/+1
In 95791be750 (doc: camelCase the i18n config variables to improve readability, 2017-07-17), the other i18n config variables were camel cased. However, this one instance was missed. Camel case and monospace "i18n.commitEncoding" so that it matches the surrounding text. Signed-off-by: Denton Liu <liu.denton@gmail.com> [jc: fixed 3 other mistakes that are exactly the same] Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-10-20Documentation: stylistically normalize references to Signed-off-by:Bradley M. Kuhn1-1/+1
Ted reported an old typo in the git-commit.txt and merge-options.txt. Namely, the phrase "Signed-off-by line" was used without either a definite nor indefinite article. Upon examination, it seems that the documentation (including items in Documentation/, but also option help strings) have been quite inconsistent on usage when referring to `Signed-off-by`. First, very few places used a definite or indefinite article with the phrase "Signed-off-by line", but that was the initial typo that led to this investigation. So, normalize using either an indefinite or definite article consistently. The original phrasing, in Commit 3f971fc425b (Documentation updates, 2005-08-14), is "Add Signed-off-by line". Commit 6f855371a53 (Add --signoff, --check, and long option-names. 2005-12-09) switched to using "Add `Signed-off-by:` line", but didn't normalize the former commit to match. Later commits seem to have cut and pasted from one or the other, which is likely how the usage became so inconsistent. Junio stated on the git mailing list in <xmqqy2k1dfoh.fsf@gitster.c.googlers.com> a preference to leave off the colon. Thus, prefer `Signed-off-by` (with backticks) for the documentation files and Signed-off-by (without backticks) for option help strings. Additionally, Junio argued that "trailer" is now the standard term to refer to `Signed-off-by`, saying that "becomes plenty clear that we are not talking about any random line in the log message". As such, prefer "trailer" over "line" anywhere the former word fits. However, leave alone those few places in documentation that use Signed-off-by to refer to the process (rather than the specific trailer), or in places where mail headers are generally discussed in comparison with Signed-off-by. Reported-by: "Theodore Y. Ts'o" <tytso@mit.edu> Signed-off-by: Bradley M. Kuhn <bkuhn@sfconservancy.org> Acked-by: Taylor Blau <me@ttaylorr.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-04-03Documentation: document am --no-gpg-signĐoàn Trần Công Danh1-1/+4
Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-02-20am: support --show-current-patch=diff to retrieve .git/rebase-apply/patchPaolo Bonzini1-5/+6
When "git am --show-current-patch" was added in commit 984913a210 ("am: add --show-current-patch", 2018-02-12), "git am" started recommending it as a replacement for .git/rebase-merge/patch. Unfortunately the suggestion is somewhat misguided; for example, the output of "git am --show-current-patch" cannot be passed to "git apply" if it is encoded as quoted-printable or base64. Add a new mode to "git am --show-current-patch" in order to straighten the suggestion. Reported-by: J. Bruce Fields <bfields@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-02-20am: support --show-current-patch=raw as a synonym for--show-current-patchPaolo Bonzini1-4/+5
When "git am --show-current-patch" was added in commit 984913a210 ("am: add --show-current-patch", 2018-02-12), "git am" started recommending it as a replacement for .git/rebase-merge/patch. Unfortunately the suggestion is somewhat misguided; for example, the output "git am --show-current-patch" cannot be passed to "git apply" if it is encoded as quoted-printable or base64. To simplify worktree operations and to avoid that users poke into .git, it would be better if "git am" also provided a mode that copies .git/rebase-merge/patch to stdout. One possibility could be to have completely separate options, introducing for example --show-current-message (for .git/rebase-apply/NNNN) and --show-current-diff (for .git/rebase-apply/patch), while possibly deprecating --show-current-patch. That would even remove the need for the first two patches in the series. However, the long common prefix would have prevented using an abbreviated option such as "--show". Therefore, I chose instead to add a string argument to --show-current-patch. The new argument is optional, so that "git am --show-current-patch"'s behavior remains backwards-compatible. The next choice to make is how to handle multiple --show-current-patch options. Right now, something like "git am --abort --show-current-patch" is rejected, and the previous suggestion would likewise have naturally rejected a command line like git am --show-current-message --show-current-diff Therefore, I decided to also reject for example git am --show-current-patch=diff --show-current-patch=raw In other words the whole of --show-current-patch=xxx (including the optional argument) is treated as the command mode. I found this to be more consistent and intuitive, even though it differs from the usual "last one wins" semantics of the git command line. Add the code to parse submodes based on the above design, where for now "raw" is the only valid submode. "raw" prints the full e-mail message just like "git am --show-current-patch". Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2020-01-08Merge branch 'pm/am-in-body-header-doc-update'Junio C Hamano1-2/+2
Doc update. * pm/am-in-body-header-doc-update: am: document that Date: can appear as an in-body header
2020-01-04am: document that Date: can appear as an in-body headerPaul Menzel1-2/+2
Similar to "From:" and "Subject:" already mentioned in the documentation, "Date:" can also appear as an in-body header to override the value in the e-mail headers. Document it. Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-10-23doc: am --show-current-patch gives an entire e-mail messageJunio C Hamano1-1/+1
The existing wording gives an impression that it only gives the contents of the $GIT_DIR/rebase-apply/patch file, i.e. the patch proper, but the option actually emits the entire e-mail message being processed (iow, one of the output files from "git mailsplit"). Signed-off-by: Junio C Hamano <gitster@pobox.com>
2019-03-18am/cherry-pick/rebase/revert: document --rerere-autoupdatePhillip Wood1-0/+5
This option was missing from the man pages of these commands. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-03-06Merge branch 'nd/rebase-show-current-patch'Junio C Hamano1-1/+5
The new "--show-current-patch" option gives an end-user facing way to get the diff being applied when "git rebase" (and "git am") stops with a conflict. * nd/rebase-show-current-patch: rebase: introduce and use pseudo-ref REBASE_HEAD rebase: add --show-current-patch am: add --show-current-patch
2018-02-14am: support --quitNguyễn Thái Ngọc Duy1-1/+5
Among the "in progress" commands, only git-am and git-merge do not support --quit. Support --quit in git-am too. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2018-02-12am: add --show-current-patchNguyễn Thái Ngọc Duy1-1/+5
Pointing the user to $GIT_DIR/rebase-apply may encourage them to mess around in there, which is not a good thing. With this, the user does not have to keep the path around somewhere (because after a couple of commands, the path may be out of scrollback buffer) when they need to look at the patch. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-07-13Merge branch 'mm/doc-tt'Junio C Hamano1-2/+2
More mark-up updates to typeset strings that are expected to literally typed by the end user in fixed-width font. * mm/doc-tt: doc: typeset HEAD and variants as literal CodingGuidelines: formatting HEAD in documentation doc: typeset long options with argument as literal doc: typeset '--' as literal doc: typeset long command-line options as literal doc: typeset short command-line options as literal Documentation/git-mv.txt: fix whitespace indentation
2016-06-28doc: typeset long command-line options as literalMatthieu Moy1-2/+2
Similarly to the previous commit, use backquotes instead of forward-quotes, for long options. This was obtained with: perl -pi -e "s/'(--[a-z][a-z=<>-]*)'/\`\$1\`/g" *.txt and manual tweak to remove false positive in ascii-art (o'--o'--o' to describe rewritten history). Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-06-06am: support --patch-format=mboxrdEric Wong1-1/+2
Combined with "git format-patch --pretty=mboxrd", this should allow us to round-trip commit messages with embedded mbox "From " lines without corruption. Signed-off-by: Eric Wong <e@80x24.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2016-01-05Expand documentation describing --signoffDavid A. Wheeler1-0/+1
Modify various document (man page) files to explain in more detail what --signoff means. This was inspired by https://lwn.net/Articles/669976/ where paulj noted, "adding [the] '-s' argument to [a] git commit doesn't really mean you have even heard of the DCO...". Extending git's documentation will make it easier to argue that developers understood --signoff when they use it. Signed-off-by: David A. Wheeler <dwheeler@dwheeler.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-10-16Merge branch 'mm/keyid-docs' into maintJunio C Hamano1-1/+3
Very small number of options take a parameter that is optional (which is not a great UI element as they can only appear at the end of the command line). Add notice to documentation of each and every one of them. * mm/keyid-docs: Documentation: explain optional arguments better Documentation/grep: fix documentation of -O Documentation: use 'keyid' consistently, not 'key-id'
2015-09-21Documentation: explain optional arguments betterMatthieu Moy1-1/+3
Improve the documentation of commands taking optional arguments in two ways: * Documents the behavior of '-O' (for grep) and '-S' (for commands creating commits) when used without the optional argument. * Document the syntax of these options. For the second point, the behavior is documented in gitcli(7), but it is easy for users to miss, and hard for the same user to understand why e.g. "git status -u no" does not work. Document this explicitly in the documentation of each short option having an optional argument: they are the most error prone since there is no '=' sign between the option and its argument. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Reviewed-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-08-04git-am: add am.threeWay config variableRemi Lespinet1-2/+5
Add the am.threeWay configuration variable to use the -3 or --3way option of git am by default. When am.threeway is set and not desired for a specific git am command, the --no-3way option can be used to override it. Signed-off-by: Remi Lespinet <remi.lespinet@ensimag.grenoble-inp.fr> Signed-off-by: Paul Tan <pyokagan@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-07-24Revert "git-am: add am.threeWay config variable"Junio C Hamano1-5/+2
This reverts commit d96a275b91bae1800cd43be0651e886e7e042a17. It used to be possible to apply a patch series with "git am mbox" and then only after seeing a failure, switch to three-way mode via "git am -3" (no other options or arguments). The commit being reverted broke this workflow. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-06-04git-am: add am.threeWay config variableRemi Lespinet1-2/+5
Add the am.threeWay configuration variable to use the -3 or --3way option of git am by default. When am.threeway is set and not desired for a specific git am command, the --no-3way option can be used to override it. Signed-off-by: Remi Lespinet <remi.lespinet@ensimag.grenoble-inp.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2015-03-05Merge branch 'mm/am-c-doc'Junio C Hamano1-1/+2
The configuration variable 'mailinfo.scissors' was hard to discover in the documentation. * mm/am-c-doc: Documentation/git-am.txt: mention mailinfo.scissors config variable Documentation/config.txt: document mailinfo.scissors
2015-02-20Documentation/git-am.txt: mention mailinfo.scissors config variableMatthieu Moy1-1/+2
It was already documented, but the user had to follow the link to git-mailinfo.txt to find it. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-12-22Merge branch 'rw/apply-does-not-take-ignore-date'Junio C Hamano1-1/+0
* rw/apply-does-not-take-ignore-date: git-am.txt: --ignore-date flag is not passed to git-apply
2014-12-09git-am.txt: --ignore-date flag is not passed to git-applyRonald Wampler1-1/+0
Signed-off-by: Ronald Wampler <rdwampler@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-11-25git-am: add --message-id/--no-message-idPaolo Bonzini1-0/+11
Parse the option and pass it directly to git-mailinfo. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-03-25Merge branch 'cp/am-patch-format-doc'Junio C Hamano1-1/+7
* cp/am-patch-format-doc: Documentation/git-am: typofix Documentation/git-am: Document supported --patch-format options
2014-03-17Documentation/git-am: typofixChris Packham1-1/+1
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-03-14Merge branch 'jn/am-doc-hooks'Junio C Hamano1-0/+5
* jn/am-doc-hooks: am doc: add a pointer to relevant hooks
2014-03-11Documentation/git-am: Document supported --patch-format optionsChris Packham1-3/+9
The --patch-format option has been supported for a while but it is not mentioned in the man page and the short help cannot tell the user what the supported formats are. Add the option to the man page along with the supported options. Signed-off-by: Chris Packham <judge.packham@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-02-24am doc: add a pointer to relevant hooksJonathan Nieder1-0/+5
It is not obvious when looking at a new command what hooks will affect it. Add a HOOKS section to the git-am(1) page, imitating git-commit(1), to make it easier for people to discover e.g. the applypatch-msg hook that can implement a custom subject-mangling strategy (e.g., removing a "bug #nnnn:" prefix introduced by a bug tracker). Reported-by: Phillip Susi <psusi@ubuntu.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-02-03am: add the --gpg-sign optionNicolas Vigier1-1/+5
Signed-off-by: Nicolas Vigier <boklm@mars-attacks.org> Signed-off-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-06-27am: replace uses of --resolved with --continueKevin Bracey1-2/+2
git am was previously modified to provide --continue for consistency with rebase, merge etc, and the documentation changed to showing --continue as the primary form. Complete the work by replacing remaining uses of --resolved by --continue, most notably in suggested command reminders. Signed-off-by: Kevin Bracey <kevin@bracey.fi> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-05-17documentation: trivial style cleanupsFelipe Contreras1-4/+3
White-spaces, missing braces, standardize --[no-]foo. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-04-20Merge branch 'jb/am-include'Junio C Hamano1-1/+2
"git am" learned the "--include" option, which is an opposite of existing the "--exclude" option. By Johannes Berg * jb/am-include: am: support --include option
2012-03-28am: support --include optionJohannes Berg1-1/+2
am supports a number of pass-through options to apply, like --exclude and --directory. Add --include to this list. Signed-off-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2012-01-29Merge branch 'tr/maint-mailinfo'Junio C Hamano1-0/+3
* tr/maint-mailinfo: mailinfo: with -b, keep space after [foo] am: learn passing -b to mailinfo Conflicts: git-am.sh
2012-01-16am: learn passing -b to mailinfoThomas Rast1-0/+3
git-am could pass -k to mailinfo, but not -b. Introduce an option that does so. We change the meaning of the 'keep' state file, but are careful not to cause a problem unless you downgrade in the middle of an 'am' run. This uncovers a bug in mailinfo -b, hence the failing test. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-08-09am: Document new --exclude=<path> optionmaximilian attems1-1/+3
The --exclude=<path> option is passed down to apply; document it as such. Signed-off-by: maximilian attems <max@stro.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-22Merge branch 'maint'Junio C Hamano1-3/+3
* maint: git-am.txt: advertise 'git am --abort' instead of 'rm .git/rebase-apply' bisect: visualize with git-log if gitk is unavailable
2011-03-22git-am.txt: advertise 'git am --abort' instead of 'rm .git/rebase-apply'SZEDER Gábor1-3/+3
'git am --abort' is around for quite a long time now, and users should normally not poke around inside the .git directory, yet the documentation of 'git am' still recommends the following: ... if you decide to start over from scratch, run `rm -f -r .git/rebase-apply` ... Suggest 'git am --abort' instead. It's not quite the same as the original, because 'git am --abort' will restore the original branch, while simply removing '.git/rebase-apply' won't, but that's rather a thinko in the original wording, because that won't actually "start over _from scratch_". Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2011-03-11doc: drop author/documentation sections from most pagesJeff King1-9/+0
The point of these sections is generally to: 1. Give credit where it is due. 2. Give the reader an idea of where to ask questions or file bug reports. But they don't do a good job of either case. For (1), they are out of date and incomplete. A much more accurate answer can be gotten through shortlog or blame. For (2), the correct contact point is generally git@vger, and even if you wanted to cc the contact point, the out-of-date and incomplete fields mean you're likely sending to somebody useless. So let's drop the fields entirely from all manpages except git(1) itself. We already point people to the mailing list for bug reports there, and we can update the Authors section to give credit to the major contributors and point to shortlog and blame for more information. Each page has a "This is part of git" footer, so people can follow that to the main git manpage.
2010-10-08Use parentheses and `...' where appropriateŠtěpán Němec1-2/+2
Remove some stray usage of other bracket types and asterisks for the same purpose. Signed-off-by: Štěpán Němec <stepnem@gmail.com> Acked-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-10Merge branch 'sh/am-keep-cr'Junio C Hamano1-1/+8
* sh/am-keep-cr: git-am: Add tests for `--keep-cr`, `--no-keep-cr` and `am.keepcr` git-am: Add am.keepcr and --no-keep-cr to override it git-am: Add command line parameter `--keep-cr` passing it to git-mailsplit documentation: 'git-mailsplit --keep-cr' is not hidden anymore
2010-03-04Merge branch 'maint-1.6.6' into maintJunio C Hamano1-1/+1
* maint-1.6.6: Remove extra '-' from git-am(1)
2010-03-04Remove extra '-' from git-am(1)Michal Sojka1-1/+1
Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-02-28git-am: Add am.keepcr and --no-keep-cr to override itStefan-W. Hahn1-2/+4
This patch adds the configuration `am.keepcr` for git-am. It also adds `--no-keep-cr` parameter for git-am to give the possibility to override configuration from command line. Signed-off-by: Stefan-W. Hahn <stefan.hahn@s-hahn.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-02-28git-am: Add command line parameter `--keep-cr` passing it to git-mailsplitStefan-W. Hahn1-1/+6
c2ca1d7 (Allow mailsplit (and hence git-am) to handle mails with CRLF line-endings, 2009-08-04) fixed "git mailsplit" to help people with MUA whose output from save-as command uses CRLF as line terminators by stripping CR at the end of lines. However, when you know you are feeding output from "git format-patch" directly to "git am", and especially when your contents have CR at the end of line, such stripping is undesirable. To help such a use case, teach --keep-cr option to "git am" and pass that to "git mailinfo". Signed-off-by: Stefan-W. Hahn <stefan.hahn@s-hahn.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-02-11am: switch --resolved to --continueJeff King1-1/+2
Rebase calls this same function "--continue", which means users may be trained to type it. There is no reason to deprecate --resolved (or -r), so we will keep it as a synonym. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-01-10Documentation: spell 'git cmd' without dash throughoutThomas Rast1-5/+5
The documentation was quite inconsistent when spelling 'git cmd' if it only refers to the program, not to some specific invocation syntax: both 'git-cmd' and 'git cmd' spellings exist. The current trend goes towards dashless forms, and there is precedent in 647ac70 (git-svn.txt: stop using dash-form of commands., 2009-07-07) to actively eliminate the dashed variants. Replace 'git-cmd' with 'git cmd' throughout, except where git-shell, git-cvsserver, git-upload-pack, git-receive-pack, and git-upload-archive are concerned, because those really live in the $PATH.
2009-09-11add documentation for mailinfo.scissors and '--no-scissors'Nicolas Sebrecht1-1/+4
Signed-off-by: Nicolas Sebrecht <nicolas.s.dev@gmx.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-26am/mailinfo: Disable scissors processing by defaultJunio C Hamano1-11/+6
You can enable it by giving --scissors to "git am". Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-26Documentation: describe the scissors mark support of "git am"Nanako Shiraishi1-4/+12
Describe what a scissors mark looks like, and explain in what situation it is often used. Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-08-05git apply: option to ignore whitespace differencesGiuseppe Bilotta1-1/+4
Introduce --ignore-whitespace option and corresponding config bool to ignore whitespace differences while applying patches, akin to the 'patch' program. 'git am', 'git rebase' and the bash git completion are made aware of this option. Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-06-18am, rebase: teach quiet optionStephen Boyd1-1/+5
git-am and git-rebase are talkative scripts. Teach them to be quiet when told, allowing them to speak only when they fail or experience errors. The quiet option is maintained when git-am or git-rebase fails to apply a patch. This means subsequent --resolved, --continue, --skip, --abort invocations will be quiet if the original invocation was quiet. Drop a handful of >&2 redirection; the rest of the program sends all the info messages to stdout, not to stderr. Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-05-05git-am.txt: reword extra headers in message bodyStephen Boyd1-4/+4
Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-05-05git-am.txt: Use date or value instead of time or timestampStephen Boyd1-4/+4
Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-05-05git-am.txt: add an 'a', say what 'it' is, simplify a sentenceStephen Boyd1-6/+6
It's nice to know that 'it' is git-am or the subject line. Whitespace implies characters so just remove characters. Signed-off-by: Stephen Boyd <bebarino@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-02Documentation: minor grammatical fixes.David J. Mellor1-18/+18
Signed-off-by: David J. Mellor <dmellor@whistlingcat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-01-25git-am: Add --ignore-date optionNanako Shiraishi1-1/+16
This new option tells 'git-am' to ignore the date header field recorded in the format-patch output. The commits will have the timestamp when they are created instead. You can work a lot in one day to accumulate many changes, but apply and push to the public repository only some of them at the end of the first day. Then next day you can spend all your working hours reading comics or chatting with your coworkers, and apply your remaining patches from the previous day using this option to pretend that you have been working at the end of the day. Signed-off-by: しらいしななこ <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-01-23git-am: implement --reject option passed to git-applymartin f. krafft1-0/+2
With --reject, git-am simply passes the --reject option to git-apply and thus allows people to work with reject files if they so prefer. Signed-off-by: martin f. krafft <madduck@madduck.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-01-12git-am: add --directory=<dir> optionJunio C Hamano1-5/+2
Thanks to a200337 (git-am: propagate -C<n>, -p<n> options as well, 2008-12-04) and commits around it, "git am" is equipped to correctly propagate the command line flags such as -C/-p/-whitespace across a patch failure and restart. It is trivial to support --directory option now, resurrecting previous attempts by Kevin and Simon. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-08-16git-am: ignore --binary optionStephan Beyer1-6/+1
The git-apply documentation says that --binary is a historical option. This patch lets git-am ignore --binary and removes advertisements of this option. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-21Rename .git/rebase to .git/rebase-applyJohannes Schindelin1-2/+2
With git-am, it sounds awkward to have the patches in ".git/rebase/", but for technical reasons, we have to keep the same directory name for git-am and git-rebase. ".git/rebase-apply" seems to be a good compromise. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-21Update my e-mail addressJunio C Hamano1-1/+1
The old cox.net address is still getting mails from gitters. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-19git am --abortNanako Shiraishi1-1/+4
After failing to apply patches in the middle of a series, "git am --abort" lets you go back to the original commit. [jc: doc/help update from Olivier, and fixups for "am -3" squashed in] Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com> Signed-off-by: Olivier Marin <dkr@freesurf.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15Rename ".dotest/" to ".git/rebase" and ".dotest-merge" to "rebase-merge"Johannes Schindelin1-2/+2
Since the files generated and used during a rebase are never to be tracked, they should live in $GIT_DIR. While at it, avoid the rather meaningless term "dotest" to "rebase", and unhide ".dotest-merge". This was wished for on the mailing list, but so far unimplemented. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Merge branch 'jc/rebase-orig-head'Junio C Hamano1-0/+6
* jc/rebase-orig-head: Documentation: mention ORIG_HEAD in am, merge, and rebase Teach "am" and "rebase" to mark the original position with ORIG_HEAD
2008-07-13git-am/git-mailsplit: correct synopsis for reading from stdinStephan Beyer1-2/+2
Invoking git-am or git-mailsplit without mbox or Maildir results in reading an mbox from stdin. Mention this in the synopsis and usage strings. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-08Documentation: mention ORIG_HEAD in am, merge, and rebaseBrian Gernhardt1-0/+6
Merge has always set ORIG_HEAD but never mentioned it, while we recently added it to am and rebase. These facts should be reflected in the documentation. git-reset also sets ORIG_HEAD, but that fact is already mentioned in the very first example so no changes were needed there. Signed-off-by: Brian Gernhardt <benji@silverinsanity.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-05manpages: italicize git command names (which were in teletype font)Jonathan Nieder1-7/+7
The names of git commands are not meant to be entered at the commandline; they are just names. So we render them in italics, as is usual for command names in manpages. Using doit () { perl -e 'for (<>) { s/\`(git-[^\`.]*)\`/'\''\1'\''/g; print }' } for i in git*.txt config.txt diff*.txt blame*.txt fetch*.txt i18n.txt \ merge*.txt pretty*.txt pull*.txt rev*.txt urls*.txt do doit <"$i" >"$i+" && mv "$i+" "$i" done git diff . Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-01Documentation: be consistent about "git-" versus "git "Jonathan Nieder1-2/+2
Since the git-* commands are not installed in $(bindir), using "git-command <parameters>" in examples in the documentation is not a good idea. On the other hand, it is nice to be able to refer to each command using one hyphenated word. (There is no escaping it, anyway: man page names cannot have spaces in them.) This patch retains the dash in naming an operation, command, program, process, or action. Complete command lines that can be entered at a shell (i.e., without options omitted) are made to use the dashless form. The changes consist only of replacing some spaces with hyphens and vice versa. After a "s/ /-/g", the unpatched and patched versions are identical. Signed-off-by: Jonathan Nieder <jrnieder@uchicago.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-06-08Docs: Use "-l::\n--long\n" format in OPTIONS sectionsStephan Beyer1-8/+16
The OPTIONS section of a documentation file contains a list of the options a git command accepts. Currently there are several variants to describe the case that different options (almost) do the same in the OPTIONS section. Some are: -f, --foo:: -f|--foo:: -f | --foo:: But AsciiDoc has the special form: -f:: --foo:: This patch applies this form to the documentation of the whole git suite, and removes useless em-dash prevention, so \--foo becomes --foo. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-06-06documentation: move git(7) to git(1)Christian Couder1-1/+1
As the "git" man page describes the "git" command at the end-user level, it seems better to move it to man section 1. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-03-05am: remove support for -d .dotestJunio C Hamano1-5/+1
It has been supported for a long time, but I do not think this feature has been in use in the real world at all. We would eventually move this out of the toplevel of the work tree and to somewhere under $GIT_DIR, so let's remove the command line option to specify the location now. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-02-25Documentation/git-am.txt: Pass -r in the example invocation of rm -f .dotestBryan Donlan1-1/+1
Signed-off-by: Bryan Donlan <bdonlan@fushizen.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-01-06Documentation: rename gitlink macro to linkgitDan McGee1-8/+8
Between AsciiDoc 8.2.2 and 8.2.3, the following change was made to the stock Asciidoc configuration: @@ -149,7 +153,10 @@ # Inline macros. # Backslash prefix required for escape processing. # (?s) re flag for line spanning. -(?su)[\\]?(?P<name>\w(\w|-)*?):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])= + +# Explicit so they can be nested. +(?su)[\\]?(?P<name>(http|https|ftp|file|mailto|callto|image|link)):(?P<target>\S*?)(\[(?P<attrlist>.*?)\])= + # Anchor: [[[id]]]. Bibliographic anchor. (?su)[\\]?\[\[\[(?P<attrlist>[\w][\w-]*?)\]\]\]=anchor3 # Anchor: [[id,xreflabel]] This default regex now matches explicit values, and unfortunately in this case gitlink was being matched by just 'link', causing the wrong inline macro template to be applied. By renaming the macro, we can avoid being matched by the wrong regex. Signed-off-by: Dan McGee <dpmcgee@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-06-07War on whitespaceJunio C Hamano1-1/+0
This uses "git-apply --whitespace=strip" to fix whitespace errors that have crept in to our source files over time. There are a few files that need to have trailing whitespaces (most notably, test vectors). The results still passes the test, and build result in Documentation/ area is unchanged. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2007-06-02Merge branches 'lh/submodules' and 'pb/am'Junio C Hamano1-3/+2
* lh/submodules: Add basic test-script for git-submodule Add git-submodule command * pb/am: Remove git-applypatch git-applymbox: Remove command
2007-06-02Fix git-am(1) synopsis formattingJonas Fonseca1-1/+0
Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-05-24Remove git-applypatchJunio C Hamano1-1/+1
The previous one removed git-applymbox, which was the sole user of this tool. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-05-24git-applymbox: Remove commandPetr Baudis1-3/+2
I believe noone uses git-applymbox, and noone definitely should, since it is supposed to be completely superseded and everything by its younger cousin git-am. The only known person in the universe to use it was Linus and he declared some time ago that he will try to use git-am instead in his famous dotest script. The trouble is that git-applymbox existence creates confusing UI. I'm a bit like a recycled newbie to the git porcelain and *I* was confused by git-applymbox primitiveness until I've realized a while later that I'm of course using the wrong command. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-05-24Teach mailsplit about Maildir'sFernando J. Pereda1-3/+5
Signed-off-by: Fernando J. Pereda <ferdy@gentoo.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-05-14git-am: Clean up the asciidoc documentationFrank Lichtenheld1-16/+19
Add --keep to synopsis. The synopsys used a mix of tabs and spaces, unify to use only spaces. Shuffle options around in synopsys and description for grouping them logically. Add more gitlink references to other commands. Various grammatical fixes and improvements. Signed-off-by: Frank Lichtenheld <frank@lichtenheld.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-04-16Update git-am documentationAndrew Ruder1-9/+16
Documentation/git-am.txt missing several short versions of options. Added documentation for --resolvemsg=<msg> command-line option. Signed-off-by: Andrew Ruder <andy@aeruder.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-24git-am documentation: describe what is taken from where.Junio C Hamano1-0/+27
Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-03-21fix typo in git-am manpageMichael S. Tsirkin1-1/+1
Fix typo in git-am manpage Signed-off-by: Michael S. Tsirkin <mst@dev.mellanox.co.il> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-11Teach git-am to pass -p option down to git-applyJunio C Hamano1-3/+4
This is originally from Andy Parkins whose patch used --patchdepth; let's use -p which is more in line with the underlying git-apply. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-11Document that git-am can read standard input.Michael S. Tsirkin1-0/+4
Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-02-08add -C[NUM] to git-amMichael S. Tsirkin1-0/+4
Add -C[NUM] to git-am and git-rebase so that patches can be applied even if context has changed a bit. Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il> Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-01-18Documentation: sync git.txt command list and manual page titleJunio C Hamano1-1/+1
Also reorders a handful entries to make each list sorted alphabetically. Signed-off-by: Junio C Hamano <junkio@cox.net>
2007-01-08--utf8 is now default for 'git-am'Junio C Hamano1-3/+16
Since we are talking about allowing potentially incompatible UI changes in v1.5.0 iff the change improves the general situation, I would say why not. There is --no-utf8 flag to avoid re-coding from botching the log message just in case, but we may not even need it. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-03-02war on whitespaces: documentation.Junio C Hamano1-2/+7
We were missing the --whitespace option in the usage string for git-apply and git-am, so this commit adds them. Signed-off-by: Junio C Hamano <junkio@cox.net>
2006-01-05Wrap synopsis lines and use [verse] to keep formattingJonas Fonseca1-0/+1
In addition, also fixes a few synopses to be more consistent and a gitlink. Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-12Documentation: more examples.Junio C Hamano1-1/+1
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-12-08Fix the description of --utf8 and --keep to git-am.Nikolai Weibull1-1/+1
The git-am script actually transform --utf8 and --keep to -u and -k when sent to git-mailinfo. Signed-off-by: Nikolai Weibull <nikolai@bitwi.se> Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-11-17git-am: --binary; document --resume and --binary.Junio C Hamano1-8/+16
Now git-apply can grok binary replacement patches, give --binary flag to git-am. As a safety measure, this is not by default enabled, so that you do not let malicious e-mailed patch to replace an arbitrary path with just a couple of lines (diff index lines, the filename and string "Binary files "...) by accident. Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-11-01git-am.txt is no stub anymorePetr Baudis1-2/+0
That notice was added by me for the emergency documentation, but Junio already expanded it to a full-fledged manual page. This patch removes the notice. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-25git-am: make it easier after fixing up an unapplicable patch.Junio C Hamano1-4/+4
Instead of having the user to edit the mail message, let the hand merge result stored in .dotest/patch and continue, which is easier to manage. Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-21Fix malformatted git-am documentation.Junio C Hamano1-1/+1
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-20Finish git-am documentation.Junio C Hamano1-10/+49
Signed-off-by: Junio C Hamano <junkio@cox.net>
2005-10-20Brief documentation for the mysterious git-am scriptPetr Baudis1-0/+51
The git-am script is nowhere called and nowhere (including itself) explained, and the name isn't helpful either. For those like me who will wonder what is it about, add some documentation stub for it to the documentation. I probably got something wrong and I don't feel like investigating all the options - this is just kind of "emergency" docs. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>