Commit Graph

31367 Commits

Author SHA1 Message Date
Junio C Hamano
990a4fea96 Merge branch 'nd/pathspec-wildcard'
Optimize matching paths with common forms of pathspecs that contain
wildcard characters.

* nd/pathspec-wildcard:
  tree_entry_interesting: do basedir compare on wildcard patterns when possible
  pathspec: apply "*.c" optimization from exclude
  pathspec: do exact comparison on the leading non-wildcard part
  pathspec: save the non-wildcard length part
2013-01-05 23:40:15 -08:00
Junio C Hamano
d65d991b65 Merge branch 'jk/fsck-dot-in-trees'
* jk/fsck-dot-in-trees:
  fsck: warn about ".git" in trees
  fsck: warn about '.' and '..' in trees
2013-01-05 23:40:04 -08:00
Junio C Hamano
e9326df9b1 Merge branch 'pf/editor-ignore-sigint'
* pf/editor-ignore-sigint:
  fix compilation with NO_PTHREADS
2013-01-05 22:48:09 -08:00
Jeff King
0398fc3496 fix compilation with NO_PTHREADS
Commit 1327452 cleaned up an unused parameter from
wait_or_whine, but forgot to update a caller that is inside
"#ifdef NO_PTHREADS".

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-05 22:47:27 -08:00
Junio C Hamano
3e293fba62 Update draft release notes to 1.8.2
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 10:33:22 -08:00
Junio C Hamano
894610af58 Merge branch 'da/p4merge-mktemp'
Create an empty file in $TMPDIR instead of using an empty file in
the local directory.

* da/p4merge-mktemp:
  mergetools/p4merge: Honor $TMPDIR for the /dev/null placeholder
2013-01-03 10:29:32 -08:00
Junio C Hamano
b81827b6b6 Merge branch 'ms/subtree-fixlets'
* ms/subtree-fixlets:
  git-subtree: fix typo in manpage
  git-subtree: ignore git-subtree executable
2013-01-03 10:29:29 -08:00
Junio C Hamano
6fedcd8188 Merge branch 'as/test-tweaks'
Output from the tests is coloured using "green is okay, yellow is
questionable, red is bad and blue is informative" scheme.

* as/test-tweaks:
  tests: paint unexpectedly fixed known breakages in bold red
  tests: test the test framework more thoroughly
  tests: refactor mechanics of testing in a sub test-lib
  tests: change info messages from yellow/brown to cyan
  tests: paint skipped tests in blue
  tests: paint known breakages in yellow
  tests: test number comes first in 'not ok $count - $message'
2013-01-03 10:29:12 -08:00
Junio C Hamano
fbe8aa792b Merge branch 'jc/same-encoding'
Finishing touches to the series to unify "Do we need to reencode
between these two encodings?" logic.

* jc/same-encoding:
  format_commit_message(): simplify calls to logmsg_reencode()
2013-01-03 10:29:09 -08:00
Junio C Hamano
d5b95853c2 Merge branch 'pf/editor-ignore-sigint'
The behaviour visible to the end users was confusing, when they
attempt to kill a process spawned in the editor that was in turn
launched by Git with SIGINT (or SIGQUIT), as Git would catch that
signal and die.  We ignore these signals now.

* pf/editor-ignore-sigint:
  launch_editor: propagate signals from editor to git
  run-command: do not warn about child death from terminal
  launch_editor: ignore terminal signals while editor has control
  launch_editor: refactor to use start/finish_command
  run-command: drop silent_exec_failure arg from wait_or_whine
2013-01-03 10:28:45 -08:00
Junio C Hamano
5f07937329 Merge branch 'mh/pthreads-autoconf'
* mh/pthreads-autoconf:
  configure.ac: fix pthreads detection on Mac OS X
2013-01-03 10:28:33 -08:00
Junio C Hamano
8cabd200d2 Merge branch 'mk/qnx'
Port to QNX.

* mk/qnx:
  Port to QNX
  Make lock local to fetch_pack
2013-01-03 10:28:33 -08:00
Junio C Hamano
324dfac8c9 Merge branch 'dm/port'
Add a few more knobs for new platform ports can tweak.

* dm/port:
  git-compat-util.h: do not #include <sys/param.h> by default
  Generalize the inclusion of strings.h
  Detect when the passwd struct is missing pw_gecos
  Support builds when sys/param.h is missing
2013-01-03 10:28:21 -08:00
Junio C Hamano
0266f4688c Merge branch 'ss/nedmalloc-compilation'
* ss/nedmalloc-compilation:
  nedmalloc: Fix a compile warning (exposed as error) with GCC 4.7.2
2013-01-03 10:14:10 -08:00
Junio C Hamano
cd46f2e59d Merge branch 'jc/maint-fnmatch-old-style-definition'
Update old-style function definition "int foo(bar) int bar; {}"
to "int foo(int bar) {}".

* jc/maint-fnmatch-old-style-definition:
  compat/fnmatch: update old-style definition to ANSI
2013-01-03 10:14:05 -08:00
Antoine Pelisse
3e4141d08c merge: Honor prepare-commit-msg return code
65969d4 (merge: honor prepare-commit-msg hook, 2011-02-14) tried to
make "git commit" and "git merge" consistent, because a merge that
required user assistance has to be concluded with "git commit", but
back then only "git commit" triggered prepare-commit-msg hook.

When it added a call to run the prepare-commit-msg hook, however, it
forgot to check the exit code from the hook like "git commit" does,
and ended up replacing one inconsistency with another.

When prepare-commit-msg hook that is run from "git merge" exits with
a non-zero status, abort the commit.

Signed-off-by: Antoine Pelisse <apelisse@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 09:10:11 -08:00
Nguyễn Thái Ngọc Duy
5ee29aefac format-patch: pick up branch description when no ref is specified
We only try to get branch name in "format-patch origin" case or
similar and not "format-patch -22" where HEAD is automatically
added. Without correct branch name, branch description cannot be
added. Make sure we always get branch name.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 09:01:38 -08:00
Jeff King
81127d74c4 tests: turn on test-lint by default
The test Makefile knows about a few "lint" checks for common
errors. However, they are not enabled as part of "make test"
by default, which means that many people do not bother
running them. Since they are both quick to run and accurate
(i.e., no false positives), there should be no harm in
turning them on and helping submitters catch errors earlier.

We could just set:

  TEST_LINT = test-lint

to enable all tests. But that would be unnecessarily
annoying later on if we add slower or less accurate tests
that should not be part of the default. Instead, we name the
tests individually.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 08:03:46 -08:00
Nguyễn Thái Ngọc Duy
20b630aae9 format-patch: pick up correct branch name from symbolic ref
find_branch_name() assumes to take refs/heads/<branch>. But we also
have symbolic refs, such as HEAD, that can point to a valid branch in
refs/heads and do not follow refs/heads/<branch> syntax. Remove the
assumption and apply normal ref resolution. After all it would be
confusing if rev machinery resolves a ref in one way and
find_branch_name() another.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 07:44:07 -08:00
Nguyễn Thái Ngọc Duy
e216cc48da t4014: a few more tests on cover letter using branch description
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 07:43:26 -08:00
Nguyễn Thái Ngọc Duy
4b5553b5f3 branch: delete branch description if it's empty
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-03 07:43:12 -08:00
Felipe Contreras
073c3ffa58 remote-bzr: detect local repositories
So we don't create a clone unnecessarily.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 20:07:00 -08:00
Felipe Contreras
570e7ecd4a remote-bzr: add support for older versions of bzr
At least as old as 2.0.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 20:06:59 -08:00
Felipe Contreras
7edea5c958 remote-bzr: add support to push special modes
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 20:06:59 -08:00
Felipe Contreras
bdeeb809d7 remote-bzr: add support for fecthing special modes
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 20:06:59 -08:00
Felipe Contreras
77b71edfb5 remote-bzr: add simple tests
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 20:06:59 -08:00
Junio C Hamano
298caa7e9e Start 1.8.2 cycle
Various fixes that have been cooking in 'next' have been merged. All
of them should go to 'maint' for 1.8.1.1 later.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 10:56:08 -08:00
Junio C Hamano
8f98074c6a Merge branch 'jc/test-portability'
* jc/test-portability:
  t9020: use configured Python to run the test helper
  t3600: Avoid "cp -a", which is a GNUism
2013-01-02 10:54:00 -08:00
Junio C Hamano
2e3c1f7a31 Merge branch 'jc/maint-fbsd-sh-ifs-workaround'
Some shells do not behave correctly when IFS is unset; work it
around by explicitly setting it to the default value.

* jc/maint-fbsd-sh-ifs-workaround:
  sh-setup: work around "unset IFS" bug in some shells
2013-01-02 10:40:41 -08:00
Junio C Hamano
71288e15df Merge branch 'sp/shortlog-missing-lf'
When a line to be wrapped has a solid run of non space characters
whose length exactly is the wrap width, "git shortlog -w" failed to
add a newline after such a line.

* sp/shortlog-missing-lf:
  strbuf_add_wrapped*(): Remove unused return value
  shortlog: fix wrapping lines of wraplen
2013-01-02 10:40:34 -08:00
Junio C Hamano
b05d8c62d3 Merge branch 'md/gitweb-sort-by-age'
"gitweb", when sorting by age to show repositories with new
activities first, used to sort repositories with absolutely nothing
in it early, which was not very useful.

* md/gitweb-sort-by-age:
  gitweb: Sort projects with undefined ages last
2013-01-02 10:40:03 -08:00
Junio C Hamano
f97335b132 Merge branch 'nd/invalidate-i-t-a-cache-tree'
After "git add -N" and then writing a tree object out of the
index, the cache-tree data structure got corrupted.

* nd/invalidate-i-t-a-cache-tree:
  cache-tree: invalidate i-t-a paths after generating trees
  cache-tree: fix writing cache-tree when CE_REMOVE is present
  cache-tree: replace "for" loops in update_one with "while" loops
  cache-tree: remove dead i-t-a code in verify_cache()
2013-01-02 10:39:51 -08:00
Junio C Hamano
229096a591 Merge branch 'jk/repack-ref-racefix'
"git pack-refs" that ran in parallel to another process that created
new refs had a nasty race.

* jk/repack-ref-racefix:
  refs: do not use cached refs in repack_without_ref
2013-01-02 10:39:37 -08:00
Junio C Hamano
77a5efb4eb Merge branch 'rb/http-cert-cred-no-username-prompt'
http transport was wrong to ask for the username when the
authentication is done by certificate identity.

* rb/http-cert-cred-no-username-prompt:
  http.c: Avoid username prompt for certifcate credentials
2013-01-02 10:39:21 -08:00
Junio C Hamano
4b32367ddc Merge branch 'mk/maint-graph-infinity-loop'
The --graph code fell into infinite loop when asked to do what the
code did not expect.

* mk/maint-graph-infinity-loop:
  graph.c: infinite loop in git whatchanged --graph -m
2013-01-02 10:39:09 -08:00
Junio C Hamano
77ecfd02de Merge branch 'ss/svn-prompt'
The way "git svn" asked for password using SSH_ASKPASS and
GIT_ASKPASS was not in line with the rest of the system.

* ss/svn-prompt:
  git-svn, perl/Git.pm: extend and use Git->prompt method for querying users
  perl/Git.pm: Honor SSH_ASKPASS as fallback if GIT_ASKPASS is not set
  git-svn, perl/Git.pm: add central method for prompting passwords
2013-01-02 10:38:50 -08:00
Junio C Hamano
9316f910f7 Merge branch 'jc/mkstemp-more-careful-error-reporting'
After failing to create a temporary file using mkstemp(), failing
pathname was not reported correctly on some platforms.

* jc/mkstemp-more-careful-error-reporting:
  xmkstemp(): avoid showing truncated template more carefully
2013-01-02 10:38:25 -08:00
Junio C Hamano
3fce9a1edd Merge branch 'jc/test-cvs-no-init-in-existing-dir'
t9200 runs "cvs init" on a directory that already exists, but a
platform can configure this fail for the current user (e.g. you need
to be in the cvsadmin group on NetBSD 6.0).

* jc/test-cvs-no-init-in-existing-dir:
  t9200: let "cvs init" create the test repository
2013-01-02 10:38:09 -08:00
Junio C Hamano
3792a75604 Merge branch 'jc/maint-test-portability'
t4014, t9502 and t0200 tests had various portability issues that
broke on OpenBSD.

* jc/maint-test-portability:
  t4014: fix arguments to grep
  t9502: do not assume GNU tar
  t0200: "locale" may not exist
2013-01-02 10:37:48 -08:00
Junio C Hamano
f470e901f2 Merge branch 'mh/ceiling'
An element on GIT_CEILING_DIRECTORIES list that does not name the
real path to a directory (i.e. a symbolic link) could have caused
the GIT_DIR discovery logic to escape the ceiling.

* mh/ceiling:
  string_list_longest_prefix(): remove function
  setup_git_directory_gently_1(): resolve symlinks in ceiling paths
  longest_ancestor_length(): require prefix list entries to be normalized
  longest_ancestor_length(): take a string_list argument for prefixes
  longest_ancestor_length(): use string_list_split()
  Introduce new function real_path_if_valid()
  real_path_internal(): add comment explaining use of cwd
  Introduce new static function real_path_internal()
2013-01-02 10:36:59 -08:00
Jonathan Nieder
122650457a build: do not automatically reconfigure unless configure.ac changed
Starting with v1.7.12-rc0~4^2 (build: reconfigure automatically if
configure.ac changes, 2012-07-19), "config.status --recheck" is
automatically run every time the "configure" script changes.  In
particular, that means the configuration procedure repeats whenever
the version number changes (since the configure script changes to
support "./configure --version" and "./configure --help"), making
bisecting painfully slow.

The intent was to make the reconfiguration process only trigger for
changes to configure.ac's logic.  Tweak the Makefile rule to match
that intent by depending on configure.ac instead of configure.

Reported-by: Martin von Zweigbergk <martinvonz@gmail.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Reviewed-by: Jeff King <peff@peff.net>
Reviewed-by: Stefano Lattarini <stefano.lattarini@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 09:47:28 -08:00
Junio C Hamano
92a865e736 SubmittingPatches: give list and maintainer addresses
We told readers to "send it to the list" (or the maintainer) without
telling what addresses are to be used.  Correct this.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 09:31:54 -08:00
Junio C Hamano
7d5bf87ba3 SubmittingPatches: remove overlong checklist
The section is no longer a concise checklist.  It also talks about
things that are not covered in the "Long version" text, which means
people need to read both, covering more or less the same thing in
different phrasing.

Fold the details into the main text and remove the section.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-02 09:31:09 -08:00
Torsten Bögershausen
279791445b t9020: which is not portable
Use type instead

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 16:44:57 -08:00
Torsten Bögershausen
6f4e5059a0 t9810: Do not use sed -i
sed -i is not portable on all systems.  Use sed with different input
and output files.  Utilize a tmp file whenever needed.

Signed-off-by: Torsten Bögershausen <tboegi@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 16:40:34 -08:00
Orgad Shaneh
0e901d24fd gitweb: fix error in sanitize when highlight is enabled
$1 becomes undef by internal regex, since it has no capture groups.

Match against accpetable control characters using index() instead of a regex.

Signed-off-by: Orgad Shaneh <orgads@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 16:27:27 -08:00
Junio C Hamano
b5fb4770ad Documentation: full-ness of a bundle is significant for cloning
Not necessarily every bundle file can be cloned from.  Only the ones
that do not need prerequisites can.

When 1d52b02 (Documentation: minor grammatical fixes and rewording
in git-bundle.txt, 2009-03-22) reworded this paragraph, it lost a
critical hint to tell readers why this particular bundle can be
cloned from.  Resurrect it.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 15:48:20 -08:00
Junio C Hamano
e6da8ee8d8 SubmittingPatches: mention subsystems with dedicated repositories
These were only mentioned in periodical "A note from the maintainer"
posting and not in the documentation suite.  SubmittingPatches has a
section to help contributors decide on what commit to base their
changes, which is the most suitable place for this information.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 14:37:56 -08:00
Junio C Hamano
adcc42e68d SubmittingPatches: who am I and who cares?
The introductory text in the "long version" talks about the origin
of this document with "I started ...", but it is unclear who that I
is, and more importantly, it is not interesting how it was started.

Just state the purpose of the document to help readers decide if it
is releavant to them.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 14:35:22 -08:00
Kirill Brilliantov
ded6aa6bda Documentation: correct example restore from bundle
Because the bundle created in the example does not record HEAD, "git
clone" will not check out the files to the working tree:

    $ git clone pr.bundle q/
    Cloning into 'q'...
    Receiving objects: 100% (619/619), 13.52 MiB | 18.74 MiB/s, done.
    Resolving deltas: 100% (413/413), done.
    warning: remote HEAD refers to nonexistent ref, unable to checkout.

Avoid alarming the readers by adding "-b master" to the example.  A
better fix may be to arrange the bundle created in the earlier step
to record HEAD, so that it can be cloned without this workaround.

Signed-off-by: Brilliantov Kirill Vladimirovich <brilliantov@inbox.ru>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2013-01-01 12:43:02 -08:00