aboutsummaryrefslogtreecommitdiff
path: root/git-am.sh
Commit message (Collapse)AuthorAge
...
| * | | | am: support --include optionJohannes Berg2012-03-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | | am: officially deprecate -b/--binary optionJunio C Hamano2012-03-13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have had these options as harmless no-op for more than 3 years without officially deprecating them. Let's announce the deprecation and start warning against their use, but without failing the command just not yet, so that we can later repurpose the option if we want to in the future. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | git-am: error out when seeing -b/--binaryThomas Rast2012-03-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The --binary option to git-apply has been a no-op since 2b6eef9 (Make apply --binary a no-op., 2006-09-06) and was deprecated in cb3a160 (git-am: ignore --binary option, 2008-08-09). We could remove it outright, but let's be nice to people who still have scripts saying 'git am -b' (if they exist) and tell them the reason for the sudden failure. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'jc/am-3-nonstandard-popt'Junio C Hamano2012-03-04
|\ \ \ \ \ | | |_|/ / | |/| | | | | | | | | | | | | | | | | | * jc/am-3-nonstandard-popt: test: "am -3" can accept non-standard -p<num> am -3: allow nonstandard -p<num> option
| * | | | am -3: allow nonstandard -p<num> optionJunio C Hamano2012-02-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When falling back to 3-way merge, we run "git apply" to synthesize the fake ancestor tree by parsing the incoming patch, and another "git apply" to apply the patch to the fake ancestor tree. Both invocation need to be aware of the custom -p<num> setting to parse patches that were prepared with non-standard src/dst prefix. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'maint'Junio C Hamano2012-02-26
|\ \ \ \ \ | | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Document accumulated fixes since 1.7.9.2 Git 1.7.8.5 grep -P: Fix matching ^ and $ am: don't infloop for an empty input file rebase -m: only call "notes copy" when rewritten exists and is non-empty git-p4: remove bash-ism in t9800 git-p4: remove bash-ism in t9809 git-p4: fix submit regression with clientSpec and subdir clone git-p4: set useClientSpec variable on initial clone Makefile: add thread-utils.h to LIB_H Conflicts: RelNotes t/t9809-git-p4-client-view.sh
| * | | | am: don't infloop for an empty input fileJim Meyering2012-02-26
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git-am.sh's check_patch_format function would attempt to preview the patch to guess its format, but would go into an infinite loop when the patch file happened to be empty. The solution: exit the loop when "read" fails, not when the line var, "$l1" becomes empty. Signed-off-by: Jim Meyering <meyering@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'tr/maint-mailinfo'Junio C Hamano2012-01-29
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | * tr/maint-mailinfo: mailinfo: with -b, keep space after [foo] am: learn passing -b to mailinfo Conflicts: git-am.sh
| * | | am: learn passing -b to mailinfoThomas Rast2012-01-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | Merge branch 'maint-1.7.7' into maintJunio C Hamano2011-12-09
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint-1.7.7: am: don't persist keepcr flag mingw: give waitpid the correct signature git symbolic-ref: documentation fix
| * | | | am: don't persist keepcr flagMartin von Zweigbergk2011-12-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The keepcr flag is only used in the split_patches function, which is only called before a patch application has to stopped for user input, not after resuming. It is therefore unnecessary to persist the flag. This seems to have been the case since it was introduced in ad2c928 (git-am: Add command line parameter `--keep-cr` passing it to git-mailsplit, 2010-02-27). Signed-off-by: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'gb/am-hg-patch'Junio C Hamano2011-10-05
|\ \ \ \ \ | |/ / / / |/| | | / | | |_|/ | |/| | * gb/am-hg-patch: am: preliminary support for hg patches
| * | | am: preliminary support for hg patchesGiuseppe Bilotta2011-08-29
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'gb/maint-am-stgit-author-to-from-fix'Junio C Hamano2011-09-02
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * gb/maint-am-stgit-author-to-from-fix: am: fix stgit patch mangling
| * | | | am: fix stgit patch manglingGiuseppe Bilotta2011-08-29
| |/ / / | | | | | | | | | | | | | | | | Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'gb/maint-am-patch-format-error-message'Junio C Hamano2011-09-02
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * gb/maint-am-patch-format-error-message: am: format is in $patch_format, not parse_patch Conflicts: git-am.sh
| * | | | am: format is in $patch_format, not parse_patchGiuseppe Bilotta2011-08-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The error message given when the patch format was not recognized was wrong, since the variable checked was $parse_patch rather than $patch_format. Fix by checking the non-emptyness of the correct variable. Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'js/i18n-scripts'Junio C Hamano2011-08-25
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * js/i18n-scripts: submodule: take advantage of gettextln and eval_gettextln. stash: take advantage of eval_gettextln pull: take advantage of eval_gettextln git-am: take advantage of gettextln and eval_gettextln. gettext: add gettextln, eval_gettextln to encode common idiom
| * | | | | git-am: take advantage of gettextln and eval_gettextln.Jon Seymour2011-08-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Jon Seymour <jon.seymour@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'db/am-skip-blank-at-the-beginning'Junio C Hamano2011-08-18
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * db/am-skip-blank-at-the-beginning: am: ignore leading whitespace before patch
| * | | | | | am: ignore leading whitespace before patchDavid Barr2011-08-11
| |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some web-based email clients prepend whitespace to raw message transcripts to workaround content-sniffing in some browsers. Adjust the patch format detection logic to ignore leading whitespace. So now you can apply patches from GMail with "git am" in three steps: 1. choose "show original" 2. tell the browser to "save as" (for example by pressing Ctrl+S) 3. run "git am" on the saved file This fixes a regression introduced by v1.6.4-rc0~15^2~2 (git-am foreign patch support: autodetect some patch formats, 2009-05-27). GMail support was first introduced to "git am" by v1.5.4-rc0~274^2 (Make mailsplit and mailinfo strip whitespace from the start of the input, 2007-11-01). Signed-off-by: David Barr <davidbarr@google.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'ma/am-exclude'Junio C Hamano2011-08-18
|\ \ \ \ \ \ | | |_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | * ma/am-exclude: am: Document new --exclude=<path> option am: pass exclude down to apply
| * | | | | am: pass exclude down to applymaximilian attems2011-08-03
| | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows to pass patches around from repositories, where the other repository doesn't feature certain files. In the special case this works for dash git sync to klibc dash: git am --directory="usr/dash" --exclude="usr/dash/configure.ac" \ --exclude="usr/dash/ChangeLog" --exclude="usr/dash/dash.1" \ .. -i -s -k ../dash/000X-foo.patch Signed-off-by: maximilian attems <max@stro.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'maint'Junio C Hamano2011-08-16
|\ \ \ \ \ | |_|/ / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Prepare for 1.7.6.1 am: refresh the index at start and --resolved Conflicts: GIT-VERSION-GEN RelNotes
| * | | | am: refresh the index at start and --resolvedJeff King2011-08-16
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a file is unchanged but stat-dirty, we may erroneously fail to apply patches, thinking that they conflict with a dirty working tree. This patch adds a call to "update-index --refresh". It comes as late as possible, so that we don't bother with it for thinks like "git rebase --abort", or when mbox-splitting fails. However, it does come before we actually start applying patches, meaning we will only call it once when we start applying patches (or any time we return to "am" after having resolved conflicts), and not once per patch. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am printf(1) message to eval_gettextÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert a message that used printf(1) format to use eval_gettext. It's easier for translators to handle the latter, since the eval format automatically gives them context via variable names. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am core say messagesÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the core git-am messages that use say() translatable. These are visible on almost every git am invocation. There are tests that depend on the "Applying" output that need to be changed to use the test_i18* functions along with this translation. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am "Falling back" say messageÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the "Falling back to patching base and 3-way merge..." message used by fall_back_3way() translatable. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am "Apply?" messageÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make the "Apply? [y]es/[n]o/[e]dit/[v]iew patch/[a]ccept all" message translatable, and leave a note in a TRANSLATORS comment explaining that translators have to preserve a mention of the y/n/e/v/a characters since the program will expect them, and not their localized equivalents. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am clean_abort messagesÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Messages that used the clean_abort function needed both gettext(1) and eval_gettext(). These need to be interpolated in a string like the die and cannot_fallback messages. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am cannot_fallback messagesÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Translate messages with gettext(1) before they're passed to the cannot_fallback function, just like we handle the die function. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am die messagesÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The die messages in git-am need to use: die "$(gettext "string")" Since gettext(1) emits the message instead of returning it like the C equivalent, and our die() function in git-sh-setup needs to get a string as an argument. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am gettext + gettext to stderr messageÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am eval_gettext messagesÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Messages that use variables to be interpolated need to use eval_gettext(), this wrapper will eval the message and expand the variable for us. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am multi-line getttext $msg; echoÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we have multi-line `gettext $msg; echo' messages we can't preserve the existing indenting because gettext(1) can't accept input on stdin. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am one-line gettext $msg; echoÆvar Arnfjörð Bjarmason2011-05-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One-line `gettext $msg; echo' messages are the simplest use case for gettext(1). Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | i18n: git-am add git-sh-i18nÆvar Arnfjörð Bjarmason2011-05-21
|/ / / | | | | | | | | | | | | | | | | | | | | | Source git-sh-i18n in git-am.sh, it's needed to import the Git gettext shell functions. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'jc/maint-rebase-rewrite-last-skip'Junio C Hamano2010-12-28
|\ \ \ | | | | | | | | | | | | | | | | * jc/maint-rebase-rewrite-last-skip: rebase --skip: correctly wrap-up when skipping the last patch
| * | | rebase --skip: correctly wrap-up when skipping the last patchJunio C Hamano2010-12-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When "rebase --skip" is used to skip the last patch in the series, the code to wrap up the rewrite by copying the notes from old to new commits and also by running the post-rewrite hook was bypassed. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'jc/maint-am-abort-safely'Junio C Hamano2010-12-22
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * jc/maint-am-abort-safely: am --abort: keep unrelated commits since the last failure and warn
| * | | | am --abort: keep unrelated commits since the last failure and warnJunio C Hamano2010-12-21
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After making commits (either by pulling or doing their own work) after a failed "am", the user will be reminded by next "am" invocation that there was a failed "am" that the user needs to decide to resolve or to get rid of the old "am" attempt. The "am --abort" option was meant to help the latter. However, it rewinded the HEAD back to the beginning of the failed "am" attempt, discarding commits made (perhaps by mistake) since. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Sync with 1.7.3.2Junio C Hamano2010-10-21
|\ \ \ \ | |/ / / | | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Merge branch 'sn/doc-opt-notation' into maintJunio C Hamano2010-10-21
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * sn/doc-opt-notation: Fix {update,checkout}-index usage strings Put a space between `<' and argument in pack-objects usage string Remove stray quotes in --pretty and --format documentation Use parentheses and `...' where appropriate Fix odd markup in --diff-filter documentation Use angles for placeholders consistently
| | * | | Use parentheses and `...' where appropriateŠtěpán Němec2010-10-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | | Merge branch 'maint'Junio C Hamano2010-10-13
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Better advice on using topic branches for kernel development Documentation: update implicit "--no-index" behavior in "git diff" Documentation: expand 'git diff' SEE ALSO section Documentation: diff can compare blobs Documentation: gitrevisions is in section 7 shell portability: no "export VAR=VAL" CodingGuidelines: reword parameter expansion section Documentation: update-index: -z applies also to --index-info Documentation: No argument of ALLOC_GROW should have side-effects
| * | | | shell portability: no "export VAR=VAL"Junio C Hamano2010-10-13
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is more portable to say "VAR=VAL && export VAR" instead. Noticed by Ævar. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | git-am: fix detection of absolute paths for windowsPat Thoyts2010-10-03
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add an is_absolute_path function to abstract out platform differences in checking for an absolute or relative path. Specifically fixes t4150-am on Windows. [PT: updated following suggestion from j6t to support \* and //*] Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Pat Thoyts <patthoyts@users.sourceforge.net>
* | | Merge branch 'js/maint-am-rebase-invalid-author'Junio C Hamano2010-06-27
|\ \ \ | | | | | | | | | | | | | | | | * js/maint-am-rebase-invalid-author: am: use get_author_ident_from_commit instead of mailinfo when rebasing
| * | | am: use get_author_ident_from_commit instead of mailinfo when rebasingJay Soffian2010-06-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In certain situations, commit authorship can consist of an invalid e-mail address. For example, this is the case when working with git svn repos where the author email has had the svn repo UUID appended such as: author@example.com <author@example.com@deadbeef-dead-beef-dead-beefdeadbeef> Given such an address, mailinfo extracts the authorship incorrectly as it assumes a valid domain. However, when rebasing the original authorship should be preserved irrespective of its validity as an email address. Using get_author_ident_from_commit instead of mailinfo when rebasing preserves the original authorship. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'rr/am-help'Junio C Hamano2010-06-18
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * rr/am-help: git am: Remove stray error message from sed git am: Display some help text when patch is empty git am: Set cmdline globally