git
10 years agorequest-pull: rewrite to C felipec/up/ruby
Felipe Contreras [Thu, 26 Sep 2013 01:38:35 +0000 (20:38 -0500)] 
request-pull: rewrite to C

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: add simpler option parser
Felipe Contreras [Sat, 28 Sep 2013 12:03:38 +0000 (07:03 -0500)] 
ruby: add simpler option parser

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: remove GIT_PAGER from environment
Felipe Contreras [Fri, 27 Sep 2013 23:55:59 +0000 (18:55 -0500)] 
ruby: remove GIT_PAGER from environment

We are not calling any git commands any more.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: remove rescue block
Felipe Contreras [Sat, 28 Sep 2013 00:15:41 +0000 (19:15 -0500)] 
ruby: request-pull: remove rescue block

We are not calling any git commands any more.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use native diff_tree stuff
Felipe Contreras [Sat, 28 Sep 2013 03:01:54 +0000 (22:01 -0500)] 
ruby: request-pull: use native diff_tree stuff

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind log_tree_diff_flush()
Felipe Contreras [Sat, 28 Sep 2013 02:56:30 +0000 (21:56 -0500)] 
ruby: bind log_tree_diff_flush()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind diff_tree_sha1()
Felipe Contreras [Sat, 28 Sep 2013 02:56:10 +0000 (21:56 -0500)] 
ruby: bind diff_tree_sha1()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use shortlog()
Felipe Contreras [Sat, 28 Sep 2013 03:00:10 +0000 (22:00 -0500)] 
ruby: request-pull: use shortlog()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind shortlog()
Felipe Contreras [Sat, 28 Sep 2013 02:54:39 +0000 (21:54 -0500)] 
ruby: bind shortlog()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: add RevInfo and DiffOptions
Felipe Contreras [Sat, 28 Sep 2013 02:53:39 +0000 (21:53 -0500)] 
ruby: add RevInfo and DiffOptions

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoshortlog: split builtin from common code
Felipe Contreras [Wed, 25 Sep 2013 15:00:45 +0000 (10:00 -0500)] 
shortlog: split builtin from common code

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoshortlog: add missing declaration
Felipe Contreras [Wed, 25 Sep 2013 14:59:40 +0000 (09:59 -0500)] 
shortlog: add missing declaration

Otherwise we would have to include commit.h.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorevision: add missing include
Felipe Contreras [Wed, 25 Sep 2013 14:42:46 +0000 (09:42 -0500)] 
revision: add missing include

Otherwise we might not have 'struct diff_options'.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use read_sha1_file()
Felipe Contreras [Sat, 28 Sep 2013 02:58:41 +0000 (21:58 -0500)] 
ruby: request-pull: use read_sha1_file()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind read_sha1_file()
Felipe Contreras [Sat, 28 Sep 2013 02:50:02 +0000 (21:50 -0500)] 
ruby: bind read_sha1_file()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use native commit info
Felipe Contreras [Tue, 24 Sep 2013 14:33:14 +0000 (09:33 -0500)] 
ruby: request-pull: use native commit info

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind find_unique_abbrev()
Felipe Contreras [Sat, 28 Sep 2013 02:46:33 +0000 (21:46 -0500)] 
ruby: bind find_unique_abbrev()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use native remote and transport
Felipe Contreras [Fri, 27 Sep 2013 23:12:06 +0000 (18:12 -0500)] 
ruby: request-pull: use native remote and transport

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind remote and transport stuff
Felipe Contreras [Fri, 27 Sep 2013 23:11:44 +0000 (18:11 -0500)] 
ruby: bind remote and transport stuff

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: trivial cleanups
Felipe Contreras [Sat, 28 Sep 2013 02:10:47 +0000 (21:10 -0500)] 
ruby: request-pull: trivial cleanups

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use get_merge_bases()
Felipe Contreras [Fri, 27 Sep 2013 23:04:21 +0000 (18:04 -0500)] 
ruby: request-pull: use get_merge_bases()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind get_merge_bases()
Felipe Contreras [Fri, 27 Sep 2013 22:50:26 +0000 (17:50 -0500)] 
ruby: bind get_merge_bases()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: add Commit class
Felipe Contreras [Fri, 27 Sep 2013 22:42:13 +0000 (17:42 -0500)] 
ruby: add Commit class

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use get_sha1()
Felipe Contreras [Fri, 27 Sep 2013 21:50:33 +0000 (16:50 -0500)] 
ruby: request-pull: use get_sha1()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: simplify tag fetching
Felipe Contreras [Fri, 27 Sep 2013 21:33:54 +0000 (16:33 -0500)] 
ruby: request-pull: simplify tag fetching

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind get_sha1()
Felipe Contreras [Fri, 27 Sep 2013 21:40:11 +0000 (16:40 -0500)] 
ruby: bind get_sha1()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind read_ref()/peel_ref()
Felipe Contreras [Fri, 27 Sep 2013 21:33:17 +0000 (16:33 -0500)] 
ruby: bind read_ref()/peel_ref()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use native git_config()
Felipe Contreras [Fri, 27 Sep 2013 20:53:38 +0000 (15:53 -0500)] 
ruby: request-pull: use native git_config()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind git_config()
Felipe Contreras [Fri, 27 Sep 2013 20:52:53 +0000 (15:52 -0500)] 
ruby: bind git_config()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: use native dwim_ref()
Felipe Contreras [Fri, 27 Sep 2013 20:11:22 +0000 (15:11 -0500)] 
ruby: request-pull: use native dwim_ref()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind dwim_ref()
Felipe Contreras [Fri, 27 Sep 2013 20:11:08 +0000 (15:11 -0500)] 
ruby: bind dwim_ref()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: bind setup_git_directory()
Felipe Contreras [Sat, 28 Sep 2013 06:08:43 +0000 (01:08 -0500)] 
ruby: bind setup_git_directory()

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: trivial simplifications
Felipe Contreras [Fri, 27 Sep 2013 19:31:16 +0000 (14:31 -0500)] 
ruby: request-pull: trivial simplifications

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: request-pull: rewrite perl script
Felipe Contreras [Sat, 21 Sep 2013 14:57:48 +0000 (09:57 -0500)] 
ruby: request-pull: rewrite perl script

Ruby can do it just fine, no need for perl.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: rewrite 'request-pull'
Felipe Contreras [Thu, 19 Sep 2013 07:07:17 +0000 (02:07 -0500)] 
ruby: rewrite 'request-pull'

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: t: add missing cat
Felipe Contreras [Sat, 28 Sep 2013 00:58:16 +0000 (19:58 -0500)] 
request-pull: t: add missing cat

Otherwise we wouldn't know why it failed.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: t: trivial whitespace style fixes
Felipe Contreras [Thu, 26 Sep 2013 15:09:44 +0000 (10:09 -0500)] 
request-pull: t: trivial whitespace style fixes

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: trivial simplification
Felipe Contreras [Fri, 27 Sep 2013 19:06:02 +0000 (14:06 -0500)] 
request-pull: trivial simplification

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: fix exact match checking
Felipe Contreras [Fri, 27 Sep 2013 19:02:41 +0000 (14:02 -0500)] 
request-pull: fix exact match checking

It obviously never worked, refs don't start with '/'.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: use appropriate ref
Felipe Contreras [Fri, 27 Sep 2013 17:56:38 +0000 (12:56 -0500)] 
request-pull: use appropriate ref

"Are you sure you pushed 'HEAD'?" doesn't say anything helpful.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: fix for specific branch
Felipe Contreras [Thu, 26 Sep 2013 16:17:48 +0000 (11:17 -0500)] 
request-pull: fix for specific branch

Wether we use a symbolic ref, or we specify the branch directly
shouldn't really matter, we would want the branch description either
way.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agorequest-pull: fix annotated tag check
Felipe Contreras [Thu, 26 Sep 2013 15:41:57 +0000 (10:41 -0500)] 
request-pull: fix annotated tag check

The was just not doing anything, reporting an appropriately tagged ref
worked only by luck.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoruby: add support for internal ruby programs
Felipe Contreras [Tue, 24 Sep 2013 00:42:08 +0000 (19:42 -0500)] 
ruby: add support for internal ruby programs

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoAdd support for ruby commands
Felipe Contreras [Wed, 12 Jun 2013 23:52:22 +0000 (18:52 -0500)] 
Add support for ruby commands

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
10 years agoGit 1.8.5-rc0 v1.8.5-rc0
Junio C Hamano [Wed, 30 Oct 2013 19:17:47 +0000 (12:17 -0700)] 
Git 1.8.5-rc0

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoMerge branch 'maint'
Junio C Hamano [Wed, 30 Oct 2013 19:11:22 +0000 (12:11 -0700)] 
Merge branch 'maint'

* maint:
  t5570: Update for clone-progress-to-stderr branch

10 years agoMerge branch 'jk/refs-c-squelch-gcc'
Junio C Hamano [Wed, 30 Oct 2013 19:11:03 +0000 (12:11 -0700)] 
Merge branch 'jk/refs-c-squelch-gcc'

* jk/refs-c-squelch-gcc:
  silence gcc array-bounds warning

10 years agoMerge branch 'jk/date-c-double-semicolon'
Junio C Hamano [Wed, 30 Oct 2013 19:11:01 +0000 (12:11 -0700)] 
Merge branch 'jk/date-c-double-semicolon'

* jk/date-c-double-semicolon:
  drop redundant semicolon in empty while

10 years agoMerge branch 'nd/lift-path-max'
Junio C Hamano [Wed, 30 Oct 2013 19:10:56 +0000 (12:10 -0700)] 
Merge branch 'nd/lift-path-max'

* nd/lift-path-max:
  checkout_entry(): clarify the use of topath[] parameter
  entry.c: convert checkout_entry to use strbuf

10 years agoMerge branch 'tr/valgrind-test-fix'
Junio C Hamano [Wed, 30 Oct 2013 19:10:52 +0000 (12:10 -0700)] 
Merge branch 'tr/valgrind-test-fix'

* tr/valgrind-test-fix:
  Revert "test-lib: allow prefixing a custom string before "ok N" etc."
  Revert "test-lib: support running tests under valgrind in parallel"

10 years agoMerge branch 'tr/gitk-doc-update'
Junio C Hamano [Wed, 30 Oct 2013 19:10:50 +0000 (12:10 -0700)] 
Merge branch 'tr/gitk-doc-update'

* tr/gitk-doc-update:
  Documentation: revamp gitk(1)

10 years agoMerge branch 'jl/pack-transfer-avoid-double-close'
Junio C Hamano [Wed, 30 Oct 2013 19:10:45 +0000 (12:10 -0700)] 
Merge branch 'jl/pack-transfer-avoid-double-close'

The codepath that send_pack() calls pack_objects() mistakenly
closed the same file descriptor twice, leading to potentially
closing a wrong file descriptor that was opened in the meantime.

* jl/pack-transfer-avoid-double-close:
  Clear fd after closing to avoid double-close error

10 years agoMerge branch 'sb/git-svn-docs-indent-with-ht'
Junio C Hamano [Wed, 30 Oct 2013 19:10:34 +0000 (12:10 -0700)] 
Merge branch 'sb/git-svn-docs-indent-with-ht'

* sb/git-svn-docs-indent-with-ht:
  git-svn docs: Use tabs consistently within the ascii doc

10 years agoMerge branch 'nd/magic-pathspec'
Junio C Hamano [Wed, 30 Oct 2013 19:10:29 +0000 (12:10 -0700)] 
Merge branch 'nd/magic-pathspec'

All callers to parse_pathspec() must choose between getting no
pathspec or one path that is limited to the current directory
when there is no paths given on the command line, but there were
two callers that violated this rule, triggering a BUG().

* nd/magic-pathspec:
  Fix calling parse_pathspec with no paths nor PATHSPEC_PREFER_* flags

10 years agoMerge branch 'nd/gc-lock-against-each-other'
Junio C Hamano [Wed, 30 Oct 2013 19:10:27 +0000 (12:10 -0700)] 
Merge branch 'nd/gc-lock-against-each-other'

* nd/gc-lock-against-each-other:
  gc: remove gc.pid file at end of execution

10 years agoMerge branch 'hn/log-graph-color-octopus'
Junio C Hamano [Wed, 30 Oct 2013 19:10:21 +0000 (12:10 -0700)] 
Merge branch 'hn/log-graph-color-octopus'

* hn/log-graph-color-octopus:
  graph: fix coloring around octopus merges

10 years agoMerge branch 'mm/checkout-auto-track-fix'
Junio C Hamano [Wed, 30 Oct 2013 19:10:16 +0000 (12:10 -0700)] 
Merge branch 'mm/checkout-auto-track-fix'

"git checkout topic", when there is not yet a local "topic" branch
but there is a unique remote-tracking branch for a remote "topic"
branch, pretended as if "git checkout -t -b topic remote/$r/topic"
(for that unique remote $r) was run. This hack however was not
implemented for "git checkout topic --".

* mm/checkout-auto-track-fix:
  checkout: proper error message on 'git checkout foo bar --'
  checkout: allow dwim for branch creation for "git checkout $branch --"

10 years agoMerge branch 'sg/t3600-nul-sha1-fix'
Junio C Hamano [Wed, 30 Oct 2013 19:10:09 +0000 (12:10 -0700)] 
Merge branch 'sg/t3600-nul-sha1-fix'

* sg/t3600-nul-sha1-fix:
  t3600: fix broken "choking git rm" test

10 years agoMerge branch 'fc/styles'
Junio C Hamano [Wed, 30 Oct 2013 19:10:06 +0000 (12:10 -0700)] 
Merge branch 'fc/styles'

C coding style fixes.

* fc/styles:
  block-sha1/sha1.c: have SP around arithmetic operators
  base85.c: have SP around arithmetic operators
  archive.c: have SP around arithmetic operators
  alloc.c: have SP around arithmetic operators
  abspath.c: have SP around arithmetic operators
  alias: have SP around arithmetic operators
  C: have space around && and || operators

10 years agoMerge branch 'jc/upload-pack-send-symref'
Junio C Hamano [Wed, 30 Oct 2013 19:10:00 +0000 (12:10 -0700)] 
Merge branch 'jc/upload-pack-send-symref'

One long-standing flaw in the pack transfer protocol used by "git
clone" was that there was no way to tell the other end which branch
"HEAD" points at, and the receiving end needed to guess.  A new
capability has been defined in the pack protocol to convey this
information so that cloning from a repository with more than one
branches pointing at the same commit where the HEAD is at now
reliably sets the initial branch in the resulting repository.

* jc/upload-pack-send-symref:
  t5570: Update for clone-progress-to-stderr branch
  t5570: Update for symref capability
  clone: test the new HEAD detection logic
  connect: annotate refs with their symref information in get_remote_head()
  connect.c: make parse_feature_value() static
  upload-pack: send non-HEAD symbolic refs
  upload-pack: send symbolic ref information as capability
  upload-pack.c: do not pass confusing cb_data to mark_our_ref()
  t5505: fix "set-head --auto with ambiguous HEAD" test

10 years agoMerge branch 'jk/http-auth-redirects'
Junio C Hamano [Wed, 30 Oct 2013 19:09:53 +0000 (12:09 -0700)] 
Merge branch 'jk/http-auth-redirects'

Handle the case where http transport gets redirected during the
authorization request better.

* jk/http-auth-redirects:
  http.c: Spell the null pointer as NULL
  remote-curl: rewrite base url from info/refs redirects
  remote-curl: store url as a strbuf
  remote-curl: make refs_url a strbuf
  http: update base URLs when we see redirects
  http: provide effective url to callers
  http: hoist credential request out of handle_curl_result
  http: refactor options to http_get_*
  http_request: factor out curlinfo_strbuf
  http_get_file: style fixes

10 years agot5570: Update for clone-progress-to-stderr branch
Brian Gernhardt [Mon, 21 Oct 2013 17:54:12 +0000 (13:54 -0400)] 
t5570: Update for clone-progress-to-stderr branch

git clone now reports its progress to standard error, which throws off
t5570.  Using test_i18ngrep instead of test_cmp allows the test to be
more flexible by only looking for the expected error and ignoring any
other output from the program.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoAlmost -rc0 for 1.8.5
Junio C Hamano [Mon, 28 Oct 2013 17:52:07 +0000 (10:52 -0700)] 
Almost -rc0 for 1.8.5

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoSync with v1.8.4.2
Junio C Hamano [Mon, 28 Oct 2013 17:51:53 +0000 (10:51 -0700)] 
Sync with v1.8.4.2

10 years agoMerge branch 'sb/repack-in-c'
Junio C Hamano [Mon, 28 Oct 2013 17:43:41 +0000 (10:43 -0700)] 
Merge branch 'sb/repack-in-c'

Finishing touches to update documentation.

* sb/repack-in-c:
  Reword repack documentation to no longer state it's a script

10 years agoMerge branch 'sg/prompt-svn-remote-fix'
Junio C Hamano [Mon, 28 Oct 2013 17:43:38 +0000 (10:43 -0700)] 
Merge branch 'sg/prompt-svn-remote-fix'

Bash portability fix.

* sg/prompt-svn-remote-fix:
  bash prompt: don't use '+=' operator in show upstream code path

10 years agoMerge branch 'jk/split-broken-ident'
Junio C Hamano [Mon, 28 Oct 2013 17:43:32 +0000 (10:43 -0700)] 
Merge branch 'jk/split-broken-ident'

Make the fall-back parsing of commit objects with broken author or
committer lines more robust to pick up the timestamps.

* jk/split-broken-ident:
  split_ident: parse timestamp from end of line

10 years agoMerge branch 'jk/remote-literal-string-leakfix'
Junio C Hamano [Mon, 28 Oct 2013 17:43:28 +0000 (10:43 -0700)] 
Merge branch 'jk/remote-literal-string-leakfix'

* jk/remote-literal-string-leakfix:
  remote: do not copy "origin" string literal

10 years agoMerge branch 'ew/keepalive'
Junio C Hamano [Mon, 28 Oct 2013 17:43:24 +0000 (10:43 -0700)] 
Merge branch 'ew/keepalive'

* ew/keepalive:
  http: use curl's tcp keepalive if available
  http: enable keepalive on TCP sockets

10 years agoMerge branch 'jc/revision-range-unpeel'
Junio C Hamano [Mon, 28 Oct 2013 17:43:16 +0000 (10:43 -0700)] 
Merge branch 'jc/revision-range-unpeel'

"git rev-list --objects ^v1.0^ v1.0" gave v1.0 tag itself in the
output, but "git rev-list --objects v1.0^..v1.0" did not.

* jc/revision-range-unpeel:
  revision: do not peel tags used in range notation

10 years agoMerge branch 'jx/relative-path-regression-fix'
Junio C Hamano [Mon, 28 Oct 2013 17:42:29 +0000 (10:42 -0700)] 
Merge branch 'jx/relative-path-regression-fix'

* jx/relative-path-regression-fix:
  Use simpler relative_path when set_git_dir
  relative_path should honor dos-drive-prefix
  test: use unambigous leading path (/foo) for MSYS

10 years agoGit 1.8.4.2 v1.8.4.2
Junio C Hamano [Mon, 28 Oct 2013 17:21:29 +0000 (10:21 -0700)] 
Git 1.8.4.2

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoMerge branch 'jk/clone-progress-to-stderr' into maint
Junio C Hamano [Mon, 28 Oct 2013 17:19:24 +0000 (10:19 -0700)] 
Merge branch 'jk/clone-progress-to-stderr' into maint

"git clone" gave some progress messages to the standard output, not to
the standard error, and did not allow suppressing them with the
"--no-progress" option.

* jk/clone-progress-to-stderr:
  clone: always set transport options
  clone: treat "checking connectivity" like other progress
  clone: send diagnostic messages to stderr

10 years agoMerge branch 'jk/format-patch-from' into maint
Junio C Hamano [Mon, 28 Oct 2013 17:18:43 +0000 (10:18 -0700)] 
Merge branch 'jk/format-patch-from' into maint

"format-patch --from=<whom>" forgot to omit unnecessary in-body from
line, i.e. when <whom> is the same as the real author.

* jk/format-patch-from:
  format-patch: print in-body "From" only when needed

10 years agoMerge branch 'jk/shortlog-tolerate-broken-commit' into maint
Junio C Hamano [Mon, 28 Oct 2013 17:17:31 +0000 (10:17 -0700)] 
Merge branch 'jk/shortlog-tolerate-broken-commit' into maint

"git shortlog" used to choke and die when there is a malformed commit
(e.g. missing authors); it now simply ignore such a commit and keeps
going.

* jk/shortlog-tolerate-broken-commit:
  shortlog: ignore commits with missing authors

10 years agoMerge branch 'jk/diff-algo' into maint
Junio C Hamano [Mon, 28 Oct 2013 17:16:11 +0000 (10:16 -0700)] 
Merge branch 'jk/diff-algo' into maint

"git merge-recursive" did not parse its "--diff-algorithm=" command
line option correctly.

* jk/diff-algo:
  merge-recursive: fix parsing of "diff-algorithm" option

10 years agotest-lib: fix typo in comment
Torstein Hegge [Sun, 27 Oct 2013 09:56:33 +0000 (10:56 +0100)] 
test-lib: fix typo in comment

Point test writers to the test_expect_* functions properly.

Signed-off-by: Torstein Hegge <hegge@resisty.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agosha1_file: move comment about return value where it belongs
Christian Couder [Sat, 26 Oct 2013 22:34:30 +0000 (00:34 +0200)] 
sha1_file: move comment about return value where it belongs

Commit 5b0864070 (sha1_object_info_extended: make type calculation
optional, Jul 12 2013) changed the return value of the
sha1_object_info_extended function to 0/-1 for success/error.

Previously this function returned the object type for success or
-1 for error. But unfortunately the above commit forgot to change
or move the comment above this function that says "returns enum
object_type or negative".

To fix this inconsistency, let's move the comment above the
sha1_object_info function where it is still true.

Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agosilence gcc array-bounds warning
Jeff King [Thu, 24 Oct 2013 08:45:13 +0000 (04:45 -0400)] 
silence gcc array-bounds warning

In shorten_unambiguous_ref, we build and cache a reverse-map of the
rev-parse rules like this:

  static char **scanf_fmts;
  static int nr_rules;
  if (!nr_rules) {
  for (; ref_rev_parse_rules[nr_rules]; nr_rules++)
  ... generate scanf_fmts ...
  }

where ref_rev_parse_rules is terminated with a NULL pointer.
Compiling with "gcc -O2 -Wall" does not cause any problems, but
compiling with "-O3 -Wall" generates:

  $ make CFLAGS='-O3 -Wall' refs.o
  refs.c: In function ‘shorten_unambiguous_ref’:
  refs.c:3379:29: warning: array subscript is above array bounds [-Warray-bounds]
     for (; ref_rev_parse_rules[nr_rules]; nr_rules++)

Curiously, we can silence this by explicitly nr_rules to 0
in the beginning of the loop, even though the compiler
should be able to tell that we follow this code path only
when nr_rules is already 0.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agodrop redundant semicolon in empty while
Jeff King [Thu, 24 Oct 2013 08:42:17 +0000 (04:42 -0400)] 
drop redundant semicolon in empty while

The extra semi-colon is harmless, since we really do want
the while loop to do nothing. But it does trigger a warning
from clang.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agocheckout_entry(): clarify the use of topath[] parameter
Junio C Hamano [Wed, 23 Oct 2013 17:52:42 +0000 (10:52 -0700)] 
checkout_entry(): clarify the use of topath[] parameter

The said function has this signature:

extern int checkout_entry(struct cache_entry *ce,
  const struct checkout *state,
  char *topath);

At first glance, it might appear that the caller of checkout_entry()
can specify to which path the contents are written out by the last
parameter, and it is tempting to add "const" in front of its type.

In reality, however, topath[] is to point at a buffer to store the
temporary path generated by the callchain originating from this
function, and the temporary path is always short, much shorter than
the buffer prepared by its only caller in builtin/checkout-index.c.

Document the code a bit to clarify so that future callers know how
to use the function better.

Noticed-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoentry.c: convert checkout_entry to use strbuf
Nguyễn Thái Ngọc Duy [Thu, 24 Oct 2013 01:55:35 +0000 (08:55 +0700)] 
entry.c: convert checkout_entry to use strbuf

The old code does not do boundary check so any paths longer than
PATH_MAX can cause buffer overflow. Replace it with strbuf to handle
paths of arbitrary length.

The OS may reject if the path is too long though. But in that case we
report the cause (e.g. name too long) and usually move on to checking
out the next entry.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agohttp.c: Spell the null pointer as NULL
Ramsay Jones [Thu, 24 Oct 2013 20:17:19 +0000 (21:17 +0100)] 
http.c: Spell the null pointer as NULL

Commit 1bbcc224 ("http: refactor options to http_get_*", 28-09-2013)
changed the type of final 'options' argument of the http_get_file()
function from an int to an 'struct http_get_options' pointer.
However, it neglected to update the (single) call site. Since this
call was passing '0' to that argument, it was (correctly) being
interpreted as a null pointer. Change to argument to NULL.

Noticed by sparse. ("Using plain integer as NULL pointer")

Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Acked-by: Jeff King <peff@peff.net>
Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoUpdate draft release notes to 1.8.5
Junio C Hamano [Wed, 23 Oct 2013 20:37:27 +0000 (13:37 -0700)] 
Update draft release notes to 1.8.5

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoSync with 'maint'
Junio C Hamano [Wed, 23 Oct 2013 20:36:57 +0000 (13:36 -0700)] 
Sync with 'maint'

10 years agoAlmost 1.8.4.2 ;-)
Junio C Hamano [Wed, 23 Oct 2013 20:34:39 +0000 (13:34 -0700)] 
Almost 1.8.4.2 ;-)

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoMerge branch 'jc/ls-files-killed-optim' into maint
Junio C Hamano [Wed, 23 Oct 2013 20:33:08 +0000 (13:33 -0700)] 
Merge branch 'jc/ls-files-killed-optim' into maint

"git ls-files -k" needs to crawl only the part of the working tree
that may overlap the paths in the index to find killed files, but
shared code with the logic to find all the untracked files, which
made it unnecessarily inefficient.

* jc/ls-files-killed-optim:
  dir.c::test_one_path(): work around directory_exists_in_index_icase() breakage
  t3010: update to demonstrate "ls-files -k" optimization pitfalls
  ls-files -k: a directory only can be killed if the index has a non-directory
  dir.c: use the cache_* macro to access the current index

10 years agoMerge branch 'jh/checkout-auto-tracking' into maint
Junio C Hamano [Wed, 23 Oct 2013 20:32:50 +0000 (13:32 -0700)] 
Merge branch 'jh/checkout-auto-tracking' into maint

"git branch --track" had a minor regression in v1.8.3.2 and later
that made it impossible to base your local work on anything but a
local branch of the upstream repository you are tracking from.

* jh/checkout-auto-tracking:
  t3200: fix failure on case-insensitive filesystems
  branch.c: Relax unnecessary requirement on upstream's remote ref name
  t3200: Add test demonstrating minor regression in 41c21f2
  Refer to branch.<name>.remote/merge when documenting --track
  t3200: Minor fix when preparing for tracking failure
  t2024: Fix &&-chaining and a couple of typos

10 years agoMerge branch 'nd/fetch-into-shallow' into maint
Junio C Hamano [Wed, 23 Oct 2013 20:32:17 +0000 (13:32 -0700)] 
Merge branch 'nd/fetch-into-shallow' into maint

When there is no sufficient overlap between old and new history
during a "git fetch" into a shallow repository, objects that the
sending side knows the receiving end has were unnecessarily sent.

* nd/fetch-into-shallow:
  Add testcase for needless objects during a shallow fetch
  list-objects: mark more commits as edges in mark_edges_uninteresting
  list-objects: reduce one argument in mark_edges_uninteresting
  upload-pack: delegate rev walking in shallow fetch to pack-objects
  shallow: add setup_temporary_shallow()
  shallow: only add shallow graft points to new shallow file
  move setup_alternate_shallow and write_shallow_commits to shallow.c

10 years agoMerge branch 'bc/gnome-keyring'
Junio C Hamano [Wed, 23 Oct 2013 20:21:50 +0000 (13:21 -0700)] 
Merge branch 'bc/gnome-keyring'

Cleanups and tweaks for credential handling to work with ancient versions
of the gnome-keyring library that are still in use.

* bc/gnome-keyring:
  contrib/git-credential-gnome-keyring.c: support really ancient gnome-keyring
  contrib/git-credential-gnome-keyring.c: support ancient gnome-keyring
  contrib/git-credential-gnome-keyring.c: report failure to store password
  contrib/git-credential-gnome-keyring.c: use glib messaging functions
  contrib/git-credential-gnome-keyring.c: use glib memory allocation functions
  contrib/git-credential-gnome-keyring.c: use secure memory for reading passwords
  contrib/git-credential-gnome-keyring.c: use secure memory functions for passwds
  contrib/git-credential-gnome-keyring.c: use gnome helpers in keyring_object()
  contrib/git-credential-gnome-keyring.c: set Gnome application name
  contrib/git-credential-gnome-keyring.c: ensure buffer is non-empty before accessing
  contrib/git-credential-gnome-keyring.c: strlen() returns size_t, not ssize_t
  contrib/git-credential-gnome-keyring.c: exit non-zero when called incorrectly
  contrib/git-credential-gnome-keyring.c: add static where applicable
  contrib/git-credential-gnome-keyring.c: *style* use "if ()" not "if()" etc.
  contrib/git-credential-gnome-keyring.c: remove unused die() function
  contrib/git-credential-gnome-keyring.c: remove unnecessary pre-declarations

10 years agoMerge branch 'po/dot-url'
Junio C Hamano [Wed, 23 Oct 2013 20:21:48 +0000 (13:21 -0700)] 
Merge branch 'po/dot-url'

Explain how '.' can be used to refer to the "current repository"
in the documentation.

* po/dot-url:
  doc/cli: make "dot repository" an independent bullet point
  config doc: update dot-repository notes
  doc: command line interface (cli) dot-repository dwimmery

10 years agoMerge branch 'jc/prompt-upstream'
Junio C Hamano [Wed, 23 Oct 2013 20:21:45 +0000 (13:21 -0700)] 
Merge branch 'jc/prompt-upstream'

An enhancement to the GIT_PS1_SHOWUPSTREAM facility.

* jc/prompt-upstream:
  git-prompt.sh: optionally show upstream branch name

10 years agoMerge branch 'hu/cherry-pick-previous-branch'
Junio C Hamano [Wed, 23 Oct 2013 20:21:35 +0000 (13:21 -0700)] 
Merge branch 'hu/cherry-pick-previous-branch'

"git cherry-pick" without further options would segfault.

Could use a follow-up to handle '-' after argv[1] better.

* hu/cherry-pick-previous-branch:
  cherry-pick: handle "-" after parsing options

10 years agoMerge branch 'mg/more-textconv'
Junio C Hamano [Wed, 23 Oct 2013 20:21:30 +0000 (13:21 -0700)] 
Merge branch 'mg/more-textconv'

Make "git grep" and "git show" pay attention to --textconv when
dealing with blob objects.

* mg/more-textconv:
  grep: honor --textconv for the case rev:path
  grep: allow to use textconv filters
  t7008: demonstrate behavior of grep with textconv
  cat-file: do not die on --textconv without textconv filters
  show: honor --textconv for blobs
  diff_opt: track whether flags have been set explicitly
  t4030: demonstrate behavior of show with textconv

10 years agoMerge branch 'jc/pack-objects'
Junio C Hamano [Wed, 23 Oct 2013 20:21:26 +0000 (13:21 -0700)] 
Merge branch 'jc/pack-objects'

* jc/pack-objects:
  pack-objects: shrink struct object_entry

10 years agoClear fd after closing to avoid double-close error
Jens Lindstrom [Tue, 22 Oct 2013 13:36:02 +0000 (15:36 +0200)] 
Clear fd after closing to avoid double-close error

In send_pack(), clear the fd passed to pack_objects() by setting
it to -1, since pack_objects() closes the fd (via a call to
run_command()).  Likewise, in get_pack(), clear the fd passed to
run_command().

Not doing so risks having git_transport_push(), caller of
send_pack(), closing the fd again, possibly incorrectly closing
some other open file; or similarly with fetch_refs_from_pack(),
indirect caller of get_pack().

Signed-off-by: Jens Lindström <jl@opera.com>
Acked-by: Jeff King <peff@peff.net>
Acked-by: Duy Nguyen <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoRevert "test-lib: allow prefixing a custom string before "ok N" etc."
Thomas Rast [Sat, 19 Oct 2013 21:06:08 +0000 (23:06 +0200)] 
Revert "test-lib: allow prefixing a custom string before "ok N" etc."

Now that ad0e623 (test-lib: support running tests under valgrind in
parallel, 2013-06-23) has been reverted, this support code has no
users any more.  Revert it, too.

This reverts commit e939e15d241e942662b9f88f6127ab470ab0a0b9.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agoRevert "test-lib: support running tests under valgrind in parallel"
Thomas Rast [Sat, 19 Oct 2013 21:06:07 +0000 (23:06 +0200)] 
Revert "test-lib: support running tests under valgrind in parallel"

This reverts commit ad0e6233320b004f0d686f6887c803e508607bd2.

--valgrind-parallel was broken from the start: during review I made
the whole valgrind setup code conditional on not being a
--valgrind-parallel worker child.  But even the children crucially
need $GIT_VALGRIND to be set; it should therefore have been set
outside the conditional.

The fix would be a two-liner, but since the introduction of the
feature, almost four months have passed without anyone noticing that
it is broken.  So this feature is not worth the about hundred lines of
test-lib.sh complexity.  Revert it.

Signed-off-by: Thomas Rast <tr@thomasrast.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agogit-svn docs: Use tabs consistently within the ascii doc
Stefan Beller [Mon, 21 Oct 2013 19:36:06 +0000 (21:36 +0200)] 
git-svn docs: Use tabs consistently within the ascii doc

While I can understand 4 or 7 white spaces are fancy, we'd rather want
to use tabs throughout the whole document.

Signed-off-by: Stefan Beller <stefanbeller@googlemail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 years agot5570: Update for clone-progress-to-stderr branch
Brian Gernhardt [Mon, 21 Oct 2013 17:54:12 +0000 (13:54 -0400)] 
t5570: Update for clone-progress-to-stderr branch

git clone now reports its progress to standard error, which throws off
t5570.  Using test_i18ngrep instead of test_cmp allows the test to be
more flexible by only looking for the expected error and ignoring any
other output from the program.

Signed-off-by: Brian Gernhardt <brian@gernhardtsoftware.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>