Commit Graph

34312 Commits

Author SHA1 Message Date
Junio C Hamano
9dc01bf063 rev-parse: introduce --exclude=<glob> to tame wildcards
Teach "rev-parse" the same "I'm going to glob, but omit the ones
that match these patterns" feature as "rev-list".

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-11-01 13:09:45 -07:00
Junio C Hamano
ff32d3420a rev-list --exclude: export add/clear-ref-exclusion and ref-excluded API
... while updating their function signature.  To be squashed into
the initial patch to rev-list.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-11-01 13:09:24 -07:00
Junio C Hamano
751a2ac6ed rev-list --exclude: tests
Add tests for the --exclude=<glob> feature.

A few tests are added for cases where use of globbing and
"--exclude" results in no positive revisions:

 * "--exclude=<glob>" before "--all" etc. resulted in no results;

 * "--stdin" is used but no input was given;

 * "--all" etc. is used but no matching refs are found.

Currently, we fail such a request with the same error message we
would give to a command line that does not specify any positive
revision (e.g. "git rev-list<ENTER>").

We may want to treat these cases differently and not error out, but
the logic to detect that would be common to all of them, so I'd
leave it outside this topic for now, and stop at adding these tests
as food-for-thought.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-11-01 13:09:23 -07:00
Johannes Sixt
574d370b06 document --exclude option
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-11-01 13:09:19 -07:00
Junio C Hamano
e7b432c521 revision: introduce --exclude=<glob> to tame wildcards
People often find "git log --branches" etc. that includes _all_
branches is cumbersome to use when they want to grab most but except
some.  The same applies to --tags, --all and --glob.

Teach the revision machinery to remember patterns, and then upon the
next such a globbing option, exclude those that match the pattern.

With this, I can view only my integration branches (e.g. maint,
master, etc.) without topic branches, which are named after two
letters from primary authors' names, slash and topic name.

    git rev-list --no-walk --exclude=??/* --branches |
    git name-rev --refs refs/heads/* --stdin

This one shows things reachable from local and remote branches that
have not been merged to the integration branches.

    git log --remotes --branches --not --exclude=??/* --branches

It may be a bit rough around the edges, in that the pattern to give
the exclude option depends on what globbing option follows.  In
these examples, the pattern "??/*" is used, not "refs/heads/??/*",
because the globbing option that follows the -"-exclude=<pattern>"
is "--branches".  As each use of globbing option resets previously
set "--exclude", this may not be such a bad thing, though.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-30 16:37:55 -07:00
Junio C Hamano
e230c568c4 Git 1.8.4
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-23 11:49:46 -07:00
Junio C Hamano
0d8beaa5b7 Typofix draft release notes to 1.8.4
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-21 15:30:04 -07:00
Junio C Hamano
4d06473928 Git 1.8.4-rc4
As we had to revert two topics at the last minute, let's have
another (hopefully short) round of rc to make sure the final release
will be sound.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-19 10:34:14 -07:00
Junio C Hamano
2c2b6646c2 Revert "Add new @ shortcut for HEAD"
This reverts commit cdfd94837b, as it
does not just apply to "@" (and forms with modifiers like @{u}
applied to it), but also affects e.g. "refs/heads/@/foo", which it
shouldn't.

The basic idea of giving a short-hand might be good, and the topic
can be retried later, but let's revert to avoid affecting existing
use cases for now for the upcoming release.
2013-08-14 15:04:24 -07:00
Junio C Hamano
c1ebd90c83 Revert "git stash: avoid data loss when "git stash save" kills a directory"
This reverts commit a73653130e, as it
has been reported that "ls-files --killed" is too time-consuming in
a deep directory with too many untracked crufts (e.g. $HOME/.git
tracking only a few files).

We'd need to revisit it later but "ls-files --killed" needs to be
optimized before it happens.
2013-08-14 09:53:43 -07:00
Junio C Hamano
425df881e0 Git 1.8.4-rc3
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-13 11:10:18 -07:00
Junio C Hamano
eaaec50fcd Merge git://github.com/git-l10n/git-po
* git://github.com/git-l10n/git-po:
  l10n: Add reference for french translation team
  l10n: fr.po: 821/2112 messages translated
2013-08-13 10:50:01 -07:00
Junio C Hamano
2809258c28 Merge branch 'sb/mailmap-updates'
* sb/mailmap-updates:
  .mailmap: Combine more (name, email) to individual persons
  .mailmap: update long-lost friends with multiple defunct addresses
2013-08-13 10:49:33 -07:00
Stefan Beller
cdb6b5ac67 .mailmap: Combine more (name, email) to individual persons
Signed-off-by: Stefan Beller <stefanbeller@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-13 10:49:06 -07:00
Junio C Hamano
10813e0d3c .mailmap: update long-lost friends with multiple defunct addresses
A handful of past contributors are recorded with multiple e-mail
addresses, all of which are undeliverable.  With a lot of help from
Jonathan, we located all of them except for one person, and a pair
of addresses we suspect belong to a single person but we are not
certain.

Update the found ones with their currently preferred address, and
use the last known address to consolidate contributions by the lost
one.

Helped-by: Stefan Beller <stefanbeller@googlemail.com>
Helped-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-13 10:47:44 -07:00
Matthieu Moy
8ed205a380 git-remote-mediawiki: ignore generated git-mw
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-13 09:52:22 -07:00
Jean-Noel Avila
1b5f46f159 l10n: Add reference for french translation team
Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
2013-08-11 17:14:58 +02:00
Jean-Noel Avila
6b388fca90 l10n: fr.po: 821/2112 messages translated
Trying to focus on most useful phrases.

Signed-off-by: Jean-Noel Avila <jn.avila@free.fr>
2013-08-11 17:14:58 +02:00
Junio C Hamano
96cb27a9d2 Merge branch 'maint'
* maint:
  parse-options: fix clang opterror() -Wunused-value warning
2013-08-09 15:49:55 -07:00
Junio C Hamano
b48493e937 Merge branch 'master' of git://github.com/git-l10n/git-po
* 'master' of git://github.com/git-l10n/git-po:
  l10n: de.po: translate 5 messages
  l10n: de.po: translate 99 new messages
  l10n: de.po: switch from pure German to German+English
  l10n: de.po: Fix a typo
  l10n: Update Swedish translation (2135t0f0u)
  l10n: zh_CN.po: translate 5 messages (2135t0f0u)
  l10n: vi.po(2135t): v1.8.4 round 2
  l10n: git.pot: v1.8.4 round 2 (5 new, 3 removed)
2013-08-09 14:31:28 -07:00
Junio C Hamano
e423a0f8a2 Merge branch 'jk/submodule-subdirectory-ok'
* jk/submodule-subdirectory-ok:
  t/t7407: fix two typos in submodule tests
2013-08-09 14:30:41 -07:00
Junio C Hamano
6f7d6ec303 Merge branch 'sb/mailmap-updates'
* sb/mailmap-updates:
  .mailmap: fixup entries
2013-08-09 14:30:13 -07:00
Stefan Beller
182be0d397 .mailmap: fixup entries
This patch adds no new names, but fixes the mistakes I made in the previous
commits. (94b410bba8, f4f49e225, c07a6bc57, 2013-07-12, .mailmap: Map
email addresses to names).

These mistakes are double white spaces between name and surname,
different capitalization in email address, or just the email address set
as name.

Also I forgot to include James Knight to the mailmap file.

Signed-off-by: Stefan Beller <stefanbeller@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-09 14:20:38 -07:00
Phil Hord
dfe338ae13 t/t7407: fix two typos in submodule tests
In t/t7407-submodule-foreach.sh there is a typo in one of the
path names given for a test step.  The correct path is
nested1/nested2/.git, but nested1/nested1/nested2/.git is
given instead.  The typo is hidden because this line also
accidentally omits the && chain operator.  The omitted chain
also means the return values of all the previous commands in
this test are also being ignored.

Fix the path and add the chain operator so the entire test
sequence can be properly validated.

Signed-off-by: Phil Hord <hordp@cisco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-09 14:00:54 -07:00
Eric Sunshine
a3bc3d070c parse-options: fix clang opterror() -Wunused-value warning
a469a10193 (silence some -Wuninitialized false positives;
2012-12-15) triggered "unused value" warnings when the return value of
opterror() and several other error-related functions was not used.
5ded807f7c (fix clang -Wunused-value warnings for error functions;
2013-01-16) applied a fix by adding #if !defined(__clang__) in cache.h
and git-compat-util.h, but misspelled it as #if !defined(clang) in
parse-options.h. Fix this.

This mistake went unnoticed because existing callers of opterror()
utilize its return value.  1158826394 (parse-options: add
OPT_CMDMODE(); 2013-07-30), however, adds a new invocation of opterror()
which ignores the return value, thus triggering the "unused value"
warning.

Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-09 09:27:44 -07:00
Ralf Thielow
4402f30155 l10n: de.po: translate 5 messages
Translate 5 new messages came from git.pot update in b8ecf23
(l10n: git.pot: v1.8.4 round 2 (5 new, 3 removed)).

Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
2013-08-09 06:53:44 +02:00
Ralf Thielow
770c73ffc9 l10n: de.po: translate 99 new messages
Translate 99 new messages came from git.pot update in
28b3cff (l10n: git.pot: v1.8.4 round 1 (99 new, 46 removed)).

Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Acked-by: Thomas Rast <trast@inf.ethz.ch>
2013-08-09 06:53:35 +02:00
Junio C Hamano
64948ad775 Git 1.8.4-rc2
This is with mostly minor documentation and test updates, nothing
spectacular except for removal of funky lstat(2) emulation on Cygwin.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-08 14:03:21 -07:00
Ralf Thielow
eb5accfece l10n: de.po: switch from pure German to German+English
This switches the translation from pure German to German+English.

Signed-off-by: Ralf Thielow <ralf.thielow@gmail.com>
Acked-by: Thomas Rast <trast@inf.ethz.ch>
2013-08-08 17:55:25 +02:00
Wieland Hoffmann
b5c0a216f8 l10n: de.po: Fix a typo
Signed-off-by: Wieland Hoffmann <themineo@gmail.com>
2013-08-08 17:55:25 +02:00
Peter Krefting
aa4e5fe40f l10n: Update Swedish translation (2135t0f0u)
Fix some incorrect translations in existing messages while at it.

Signed-off-by: Peter Krefting <peter@softwolves.pp.se>
2013-08-06 12:44:17 +01:00
Jiang Xin
b18943845c l10n: zh_CN.po: translate 5 messages (2135t0f0u)
Translate 5 new messages came from git.pot update in b8ecf23
(l10n: git.pot: v1.8.4 round 2 (5 new, 3 removed)).

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2013-08-06 17:22:16 +08:00
Tran Ngoc Quan
85ef881f6c l10n: vi.po(2135t): v1.8.4 round 2
Signed-off-by: Tran Ngoc Quan <vnwildman@gmail.com>
2013-08-06 14:34:48 +07:00
Jiang Xin
b8ecf239d0 l10n: git.pot: v1.8.4 round 2 (5 new, 3 removed)
Generate po/git.pot from v1.8.4-rc1-21-gfb56570 for git v1.8.4
l10n round 2.

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2013-08-06 14:13:23 +08:00
Junio C Hamano
fb56570821 Sync with maint to grab trivial doc fixes
* maint:
  fix typo in documentation of git-svn
  Documentation/rev-list-options: add missing word in --*-parents
  log doc: the argument to --encoding is not optional
2013-08-05 13:00:20 -07:00
Junio C Hamano
f5206f1239 Merge branch 'es/blame-L-breakage'
* es/blame-L-breakage:
  t8001, t8002: fix "blame -L :literal" test on NetBSD
2013-08-05 10:44:39 -07:00
René Scharfe
3a4fc21a29 t8001, t8002: fix "blame -L :literal" test on NetBSD
Sub-test 42 of t8001 and t8002 ("blame -L :literal") fails on NetBSD
with the following verbose output:

	git annotate  -L:main hello.c
	Author F (expected 4, attributed 3) bad
	Author G (expected 1, attributed 1) good

This is not caused by different behaviour of git blame or annotate on
that platform, but by different test input, in turn caused by a sed
command that forgets to add a newline on NetBSD.  Here's the diff of the
commit that adds "goodbye" to hello.c, for Linux:

	@@ -1,4 +1,5 @@
	 int main(int argc, const char *argv[])
	 {
		puts("hello");
	+		puts("goodbye");
	 }

We see that it adds an extra TAB, but that's not a problem.  Here's the
same on NetBSD:

	@@ -1,4 +1,4 @@
	 int main(int argc, const char *argv[])
	 {
		puts("hello");
	-}
	+		puts("goodbye");}

It also adds an extra TAB, but it is missing the newline character
after the semicolon.

The following patch gets rid of the extra TAB at the beginning, but
more importantly adds the missing newline at the end in a (hopefully)
portable way, mentioned in http://sed.sourceforge.net/sedfaq4.html.
The diff becomes this, on both Linux and NetBSD:

	@@ -1,4 +1,5 @@
	 int main(int argc, const char *argv[])
	 {
		puts("hello");
	+	puts("goodbye");
	 }

Signed-off-by: Rene Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 10:43:28 -07:00
Junio C Hamano
a48ed48db5 Merge git://github.com/git-l10n/git-po
* git://github.com/git-l10n/git-po:
  l10n: zh_CN.po: translate 99 messages (2133t0f0u)
  l10n: vi.po (2133t)
  l10n: git.pot: v1.8.4 round 1 (99 new, 46 removed)
2013-08-05 10:38:23 -07:00
Junio C Hamano
4fcd30df85 Merge branch 'sb/mailmap-updates'
* sb/mailmap-updates:
  .mailmap: Multiple addresses of Michael S. Tsirkin
2013-08-05 10:11:14 -07:00
Junio C Hamano
d6f3ab573e Merge branch 'dn/test-reject-utf-16'
* dn/test-reject-utf-16:
  t3900: test rejecting log message with NULs correctly
  Add missing test file for UTF-16.
2013-08-05 10:11:10 -07:00
Junio C Hamano
c8abf659f7 Merge branch 'bc/commit-invalid-utf8'
* bc/commit-invalid-utf8:
  commit: typofix for xxFFF[EF] check
2013-08-05 10:11:04 -07:00
Junio C Hamano
dc773a67e1 commit: typofix for xxFFF[EF] check
We wanted to catch all codepoints that ends with FFFE and FFFF,
not with 0FFFE and 0FFFF.

Noticed and corrected by Peter Krefting.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 09:53:38 -07:00
Junio C Hamano
0ed45a1cd6 t3900: test rejecting log message with NULs correctly
It is not like that our longer term desire is to someday start
accept log messages with NULs in them, so it is wrong to mark a test
that demonstrates "git commit" that correctly fails given such an
input as "expect-failure".  "git commit" should fail today, and it
should fail the same way in the future given a message with NUL in it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 09:47:11 -07:00
Brian M. Carlson
214a5f2e0c Add missing test file for UTF-16.
The test file that the UTF-16 rejection test looks for is missing, but this went
unnoticed because the test is expected to fail anyway; as a consequence, the
test fails because the file containing the commit message is missing, and not
because the test file contains a NUL byte.  Fix this by including a sample text
file containing a commit message encoded in UTF-16.

Signed-off-by: Brian M. Carlson <sandals@crustytoothpaste.net>
Tested-by: Duy Nguyen <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 09:46:47 -07:00
Felix Gruber
0bf5ce4ef2 fix typo in documentation of git-svn
Signed-off-by: Felix Gruber <felgru@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 09:39:01 -07:00
Torstein Hegge
5104d21fbd Documentation/rev-list-options: add missing word in --*-parents
A commit has "parent commits" or "parents", not "commits".

Signed-off-by: Torstein Hegge <hegge@resisty.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 08:47:06 -07:00
Stefan Beller
487e570785 .mailmap: Multiple addresses of Michael S. Tsirkin
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Stefan Beller <stefanbeller@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 08:27:42 -07:00
Jonathan Nieder
e6604c3537 log doc: the argument to --encoding is not optional
$ git log --encoding
 fatal: Option '--encoding' requires a value
 $ git rev-list --encoding
 fatal: Option '--encoding' requires a value

The argument to --encoding has always been mandatory.  Unfortunately
manpages like git-rev-list(1), git-log(1), and git-show(1) have
described the option's syntax as "--encoding[=<encoding>]" since it
was first documented.  Clarify by removing the extra brackets.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-08-05 08:19:47 -07:00
Jiang Xin
2e8451e860 l10n: zh_CN.po: translate 99 messages (2133t0f0u)
Translate 99 new messages came from git.pot update in 28b3cff
(l10n: git.pot: v1.8.4 round 1 (99 new, 46 removed)).

Signed-off-by: Jiang Xin <worldhello.net@gmail.com>
2013-08-03 14:14:07 +08:00
Junio C Hamano
d6cbf2fa7a Merge branch 'rj/cygwin-clarify-use-of-cheating-lstat'
Cygwin port added a "not quite correct but a lot faster and good
enough for many lstat() calls that are only used to see if the
working tree entity matches the index entry" lstat() emulation some
time ago, and it started biting us in places.  This removes it and
uses the standard lstat() that comes with Cygwin.

Recent topic that uses lstat on packed-refs file is broken when
this cheating lstat is used, and this is a simplest fix that is
also the cleanest direction to go in the long run.

* rj/cygwin-clarify-use-of-cheating-lstat:
  cygwin: Remove the Win32 l/stat() implementation
2013-08-02 11:01:01 -07:00