summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2010-08-02 19:02:16 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-08-02 19:02:16 (GMT)
commit9d52f15af7de943779cf6302cef4f1a88ce447be (patch)
tree53c0f1a56674b66491cd0e6942fca82b5a1968e9
parent8a883b0260ba7f8d6e4c025ae3c32b454e80ade5 (diff)
parent7d808125a0197e5660a57f77d14937604b16e39a (diff)
downloadgit-9d52f15af7de943779cf6302cef4f1a88ce447be.zip
git-9d52f15af7de943779cf6302cef4f1a88ce447be.tar.gz
git-9d52f15af7de943779cf6302cef4f1a88ce447be.tar.bz2
Merge branch 'maint'
* maint: test-lib: Remove 3 year old no-op --no-python option test-lib: Ignore --quiet under a TAP harness Documentation/rev-parse: quoting is required with --parseopt Documentation: reporting bugs Fix git rebase --continue to work with touched files Document ls-files -t as semi-obsolete.
-rw-r--r--Documentation/git-ls-files.txt12
-rw-r--r--Documentation/git-rev-parse.txt7
-rw-r--r--Documentation/git.txt7
-rwxr-xr-xgit-rebase.sh1
-rwxr-xr-xt/t3418-rebase-continue.sh43
-rw-r--r--t/test-lib.sh7
6 files changed, 69 insertions, 8 deletions
diff --git a/Documentation/git-ls-files.txt b/Documentation/git-ls-files.txt
index 3521637..bd919f2 100644
--- a/Documentation/git-ls-files.txt
+++ b/Documentation/git-ls-files.txt
@@ -106,8 +106,16 @@ OPTIONS
with `-s` or `-u` options does not make any sense.
-t::
- Identify the file status with the following tags (followed by
- a space) at the start of each line:
+ This feature is semi-deprecated. For scripting purpose,
+ linkgit:git-status[1] `--porcelain` and
+ linkgit:git-diff-files[1] `--name-status` are almost always
+ superior alternatives, and users should look at
+ linkgit:git-status[1] `--short` or linkgit:git-diff[1]
+ `--name-status` for more user-friendly alternatives.
++
+This option identifies the file status with the following tags (followed by
+a space) at the start of each line:
+
H:: cached
S:: skip-worktree
M:: unmerged
diff --git a/Documentation/git-rev-parse.txt b/Documentation/git-rev-parse.txt
index 0727f43..be4c053 100644
--- a/Documentation/git-rev-parse.txt
+++ b/Documentation/git-rev-parse.txt
@@ -184,10 +184,13 @@ scripts the same facilities C builtins have. It works as an option normalizer
(e.g. splits single switches aggregate values), a bit like `getopt(1)` does.
It takes on the standard input the specification of the options to parse and
-understand, and echoes on the standard output a line suitable for `sh(1)` `eval`
+understand, and echoes on the standard output a string suitable for `sh(1)` `eval`
to replace the arguments with normalized ones. In case of error, it outputs
usage on the standard error stream, and exits with code 129.
+Note: Make sure you quote the result when passing it to `eval`. See
+below for an example.
+
Input Format
~~~~~~~~~~~~
@@ -244,7 +247,7 @@ bar= some cool option --bar with an argument
An option group Header
C? option C with an optional argument"
-eval `echo "$OPTS_SPEC" | git rev-parse --parseopt -- "$@" || echo exit $?`
+eval "$(echo "$OPTS_SPEC" | git rev-parse --parseopt -- "$@" || echo exit $?)"
------------
SQ-QUOTE
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 59f291d..c28a7ec 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -727,6 +727,13 @@ The documentation for git suite was started by David Greaves
<david@dgreaves.com>, and later enhanced greatly by the
contributors on the git-list <git@vger.kernel.org>.
+Reporting Bugs
+--------------
+
+Report bugs to the Git mailing list <git@vger.kernel.org> where the
+development and maintenance is primarily done. You do not have to be
+subscribed to the list to send a message there.
+
SEE ALSO
--------
linkgit:gittutorial[7], linkgit:gittutorial-2[7],
diff --git a/git-rebase.sh b/git-rebase.sh
index ab4afa7..2d88742 100755
--- a/git-rebase.sh
+++ b/git-rebase.sh
@@ -208,6 +208,7 @@ do
test -d "$dotest" -o -d "$GIT_DIR"/rebase-apply ||
die "No rebase in progress?"
+ git update-index --ignore-submodules --refresh &&
git diff-files --quiet --ignore-submodules || {
echo "You must edit all merge conflicts and then"
echo "mark them as resolved using git add"
diff --git a/t/t3418-rebase-continue.sh b/t/t3418-rebase-continue.sh
new file mode 100755
index 0000000..3b0d273
--- /dev/null
+++ b/t/t3418-rebase-continue.sh
@@ -0,0 +1,43 @@
+#!/bin/sh
+
+test_description='git rebase --continue tests'
+
+. ./test-lib.sh
+
+. "$TEST_DIRECTORY"/lib-rebase.sh
+
+set_fake_editor
+
+test_expect_success 'setup' '
+ test_commit "commit-new-file-F1" F1 1 &&
+ test_commit "commit-new-file-F2" F2 2 &&
+
+ git checkout -b topic HEAD^ &&
+ test_commit "commit-new-file-F2-on-topic-branch" F2 22 &&
+
+ git checkout master
+'
+
+test_expect_success 'interactive rebase --continue works with touched file' '
+ rm -fr .git/rebase-* &&
+ git reset --hard &&
+ git checkout master &&
+
+ FAKE_LINES="edit 1" git rebase -i HEAD^ &&
+ test-chmtime =-60 F1 &&
+ git rebase --continue
+'
+
+test_expect_success 'non-interactive rebase --continue works with touched file' '
+ rm -fr .git/rebase-* &&
+ git reset --hard &&
+ git checkout master &&
+
+ test_must_fail git rebase --onto master master topic &&
+ echo "Resolved" >F2 &&
+ git add F2 &&
+ test-chmtime =-60 F1 &&
+ git rebase --continue
+'
+
+test_done
diff --git a/t/test-lib.sh b/t/test-lib.sh
index e5523dd..e8f21d5 100644
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
@@ -127,14 +127,13 @@ do
-v|--v|--ve|--ver|--verb|--verbo|--verbos|--verbose)
verbose=t; shift ;;
-q|--q|--qu|--qui|--quie|--quiet)
- quiet=t; shift ;;
+ # Ignore --quiet under a TAP::Harness. Saying how many tests
+ # passed without the ok/not ok details is always an error.
+ test -z "$HARNESS_ACTIVE" && quiet=t; shift ;;
--with-dashes)
with_dashes=t; shift ;;
--no-color)
color=; shift ;;
- --no-python)
- # noop now...
- shift ;;
--va|--val|--valg|--valgr|--valgri|--valgrin|--valgrind)
valgrind=t; verbose=t; shift ;;
--tee)