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.
This commit is contained in:
Junio C Hamano 2010-08-02 12:02:16 -07:00
commit 9d52f15af7
6 changed files with 69 additions and 8 deletions

View File

@ -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

View File

@ -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

View File

@ -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],

View File

@ -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"

43
t/t3418-rebase-continue.sh Executable file
View File

@ -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

View File

@ -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)