summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2008-09-30Replace svn.foo.org with svn.example.com in git-svn docs (RFC 2606)Michael Prokop
foo.org is an existing domain, use RFC 2606 complying example.com instead as used in other docs as well. Signed-off-by: Michael Prokop <mika@grml.org> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-30t0024: add executable permissionSZEDER Gábor
Signed-off-by: SZEDER Gábor <szeder@ira.uka.de> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29Merge branch 'bc/maint-diff-hunk-header-fix' into maintShawn O. Pearce
* bc/maint-diff-hunk-header-fix: t4018-diff-funcname: test syntax of builtin xfuncname patterns diff hunk pattern: fix misconverted "\{" tex macro introducers diff: use extended regexp to find hunk headers diff.*.xfuncname which uses "extended" regex's for hunk header selection diff.c: associate a flag with each pattern and use it for compiling regex diff.c: return pattern entry pointer rather than just the hunk header pattern Conflicts: Documentation/gitattributes.txt
2008-09-29Merge branch 'mg/maint-remote-fix' into maintShawn O. Pearce
* mg/maint-remote-fix: make "git remote" report multiple URLs
2008-09-29Clarify commit error message for unmerged filesRafael Garcia-Suarez
Currently, trying to use git-commit with unmerged files in the index will show the message "Error building trees", which can be a bit obscure to the end user. This patch makes the error message clearer, and consistent with what git-write-tree reports in a similar situation. Signed-off-by: Rafael Garcia-Suarez <rgarciasuarez@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29Use strchrnul() instead of strchr() plus manual workaroundJohan Herland
Also gets rid of a C++ comment. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29Use remove_path from dir.c instead of own implementationAlex Riesen
Besides, it fixes a memleak (builtin-rm.c) and accidental change of the input const argument (builtin-merge-recursive.c). Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29Add remove_path: a function to remove as much as possible of a pathAlex Riesen
The function has two potential users which both managed to get wrong their implementations (the one in builtin-rm.c one has a memleak, and builtin-merge-recursive.c scribles over its const argument). Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29git-submodule: Fix "Unable to checkout" for the initial 'update'Ping Yin
Since commit 55218("checkout: do not lose staged removal"), in cmd_add/cmd_update, "git checkout <commit>" following "git clone -n" may fail if <commit> is different from HEAD. So Use "git checkout -f <commit>" to fix this. Signed-off-by: Ping Yin <pkufranky@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-29Clarify how the user can satisfy stash's 'dirty state' check.Stephen Haberman
Signed-off-by: Stephen Haberman <stephen@exigencecorp.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-26Remove empty directories in recursive mergeAlex Riesen
The code was actually supposed to do that, but was accidentally broken. Noticed by Anders Melchiorsen. Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-26Documentation: clarify the details of overriding LESS via core.pagerChris Frey
The process of overriding the default LESS options using only git-specific methods is rather obscure. Show the end user how to do it in a step-by-step manner. Signed-off-by: Chris Frey <cdfrey@foursquare.net> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-25Update release notes for 1.6.0.3Shawn O. Pearce
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-25checkout: Do not show local changes when in quiet modeJonas Fonseca
Signed-off-by: Jonas Fonseca <fonseca@diku.dk> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-25for-each-ref: Fix --format=%(subject) for log message without newlinesJohan Herland
'git for-each-ref --format=%(subject)' currently returns an empty string if the log message does not contain a newline. This patch teaches 'git for-each-ref' to return the entire log message (instead of an empty string) if there is no newline in the log message. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-24git-stash.sh: don't default to refs/stash if invalid ref suppliedBrandon Casey
apply_stash() and show_stash() each call rev-parse with '--default refs/stash' as an argument. This option causes rev-parse to operate on refs/stash if it is not able to successfully operate on any element of the command line. This includes failure to supply a "valid" revision. This has the effect of causing 'stash apply' and 'stash show' to operate as if stash@{0} had been supplied when an invalid revision is supplied. e.g. 'git stash apply stash@{1}' would fall back to 'git stash apply stash@{0}' This patch modifies these two functions so that they avoid using the --default option of rev-parse. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-24maint: check return of split_cmdline to avoid bad config stringsDeskin Miller
As the testcase demonstrates, it's possible for split_cmdline to return -1 and deallocate any memory it's allocated, if the config string is missing an end quote. In both the cases below, which are the only calling sites, the return isn't checked, and using the pointer causes a pretty immediate segfault. Signed-off-by: Deskin Miller <deskinm@umich.edu> Acked-by: Miklos Vajna <vmiklos@frugalware.org> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
2008-09-23builtin-prune.c: prune temporary packs in <object_dir>/pack directoryBrandon Casey
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-23t4018-diff-funcname: test syntax of builtin xfuncname patternsBrandon Casey
Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-22Do not perform cross-directory renames when creating packsPetr Baudis
A comment on top of create_tmpfile() describes caveats ('can have problems on various systems (FAT, NFS, Coda)') that should apply in this situation as well. This in the end did not end up solving any of my personal problems, but it might be a useful cleanup patch nevertheless. Signed-off-by: Petr Baudis <pasky@suse.cz> Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-22Use dashless git commands in setgitperms.perlTodd Zullinger
Signed-off-by: Todd Zullinger <tmz@pobox.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-22git-remote: do not use user input in a printf format stringJohannes Sixt
'git remote show' substituted the remote name into a string that was later used as a printf format string. If a remote name contains a printf format specifier like this: $ git remote add foo%sbar . then the command $ git remote show foo%sbar would print garbage (if you are lucky) or crash. This fixes it. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-22make "git remote" report multiple URLsMichael J Gruber
This patch makes "git remote -v" and "git remote show" report multiple URLs rather than warn about them. Multiple URLs are OK for pushing into multiple repos simultaneously. Without "-v" each repo is shown once only. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-22Check early that a new branch is new and validDaniel Barkalow
If you fail to update refs to change branches in checkout, your index and working tree are left already updated. We don't have an easy way to undo this, but at least we can check things that would make the creation of a new branch fail. These checks were in the shell version, and were lost in the C conversion. The messages are from the shell version, and should probably be made nicer. [jc: added test to t7201] Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20diff hunk pattern: fix misconverted "\{" tex macro introducersJunio C Hamano
Pointed out by Brandon Casey. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20diff: use extended regexp to find hunk headersJunio C Hamano
Using ERE elements such as "|" (alternation) by backquoting in BRE is a GNU extension and should not be done in portable programs. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20Start draft release notes for 1.6.0.3Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20git-repack uses --no-repack-object, not --no-repack-delta.Mikael Magnusson
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20Typo "bogos" in format-patch error message.Mikael Magnusson
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20builtin-clone: fix typoFabrizio Chiarello
Signed-off-by: Fabrizio Chiarello <ponch@autistici.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20Bust the ghost of long-defunct diffcore-pathspec.Yann Dirson
This concept was retired by 77882f6 (Retire diffcore-pathspec., 2006-04-10), more than 2 years ago. Signed-off-by: Yann Dirson <ydirson@altern.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-20completion: git commit should list --interactiveEric Raible
Signed-off-by: Eric Raible <raible@gmail.com> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19diff.*.xfuncname which uses "extended" regex's for hunk header selectionBrandon Casey
Currently, the hunk headers produced by 'diff -p' are customizable by setting the diff.*.funcname option in the config file. The 'funcname' option takes a basic regular expression. This functionality was designed using the GNU regex library which, by default, allows using backslashed versions of some extended regular expression operators, even in Basic Regular Expression mode. For example, the following characters, when backslashed, are interpreted according to the extended regular expression rules: ?, +, and |. As such, the builtin funcname patterns were created using some extended regular expression operators. Other platforms which adhere more strictly to the POSIX spec do not interpret the backslashed extended RE operators in Basic Regular Expression mode. This causes the pattern matching for the builtin funcname patterns to fail on those platforms. Introduce a new option 'xfuncname' which uses extended regular expressions, and advertise it _instead_ of funcname. Since most users are on GNU platforms, the majority of funcname patterns are created and tested there. Advertising only xfuncname should help to avoid the creation of non-portable patterns which work with GNU regex but not elsewhere. Additionally, the extended regular expressions may be less ugly and complicated compared to the basic RE since many common special operators do not need to be backslashed. For example, the GNU Basic RE: ^[ ]*\\(\\(public\\|static\\).*\\)$ becomes the following Extended RE: ^[ ]*((public|static).*)$ Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19diff.c: associate a flag with each pattern and use it for compiling regexBrandon Casey
This is in preparation for allowing extended regular expression patterns. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19diff.c: return pattern entry pointer rather than just the hunk header patternBrandon Casey
This is in preparation for associating a flag with each pattern which will control how the pattern is interpreted. For example, as a basic or extended regular expression. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19Merge branch 'dp/maint-rebase-fix' into maintJunio C Hamano
* dp/maint-rebase-fix: git-rebase--interactive: auto amend only edited commit git-rebase-interactive: do not squash commits on abort
2008-09-19Merge branch 'jc/maint-checkout-keep-remove' into maintJunio C Hamano
* jc/maint-checkout-keep-remove: checkout: do not lose staged removal
2008-09-19Merge branch 'jc/maint-diff-quiet' into maintJunio C Hamano
* jc/maint-diff-quiet: diff --quiet: make it synonym to --exit-code >/dev/null diff Porcelain: do not disable auto index refreshing on -C -C
2008-09-19Merge branch 'jc/maint-name-hash-clear' into maintJunio C Hamano
* jc/maint-name-hash-clear: discard_cache: reset lazy name_hash bit
2008-09-19Merge branch 'jc/maint-template-permbits' into maintJunio C Hamano
* jc/maint-template-permbits: Fix permission bits on sources checked out with an overtight umask
2008-09-19Merge branch 'mh/maint-honor-no-ssl-verify' into maintJunio C Hamano
* mh/maint-honor-no-ssl-verify: Don't verify host name in SSL certs when GIT_SSL_NO_VERIFY is set
2008-09-19sha1_file: link() returns -1 on failure, not errnoThomas Rast
5723fe7 (Avoid cross-directory renames and linking on object creation, 2008-06-14) changed the call to use link() directly instead of through a custom wrapper, but forgot that it returns 0 or -1, not 0 or errno. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19Make git archive respect core.autocrlf when creating zip format archivesCharles Bailey
There is currently no call to git_config at the start of cmd_archive. When creating tar archives the core config is read as a side-effect of reading the tar specific config, but this doesn't happen for zip archives. The consequence is that in a configuration with core.autocrlf set, although files in a tar archive are created with crlf line endings, files in a zip archive retain unix line endings. Signed-off-by: Charles Bailey <charles@hashpling.org> Acked-by: René Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19Add new test to demonstrate git archive core.autocrlf inconsistencyCharles Bailey
Signed-off-by: Charles Bailey <charles@hashpling.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19gitweb: avoid warnings for commits without bodyJoey Hess
In the unusual case when there is no commit message, gitweb would output an uninitialized value warning. Signed-off-by: Joey Hess <joey@kitenet.net> Acked-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19Clarified gitattributes documentation regarding custom hunk header.Garry Dolley
The only part of the hunk header that we can change is the "TEXT" portion. Additionally, a few grammatical errors have been corrected. Signed-off-by: Garry Dolley <gdolley@ucla.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19git-svn: fix handling of even funkier branch namesEric Wong
Apparently do_switch() tolerates the lack of escaping in less funky branch names. For the really strange and scary ones, we need to escape them properly. It strangely maintains compatible with the existing handling of branch names with spaces and exclamation marks. Reported-by: m.skoric@web.de ($gmane/94677) Signed-off-by: Eric Wong <normalperson@yhbt.net>
2008-09-19git-svn: Always create a new RA when calling do_switch for svn://Alec Berryman
Not doing so caused the "Malformed network data" error when a directoy was deleted and replaced with a copy from an older version. Signed-off-by: Alec Berryman <alec@thened.net> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-19git-svn: factor out svnserve test code for later useAlec Berryman
Signed-off-by: Alec Berryman <alec@thened.net> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-09-18diff/diff-files: do not use --cc too aggressivelyJunio C Hamano
Textual diff output for unmerged paths was too eager to give condensed combined diff. Even though "diff -c" (and "diff-files -c -p") is a request to view combined diff without condensing (otherwise the user would have explicitly asked for --cc, not -c), we showed "--cc" output anyway. 0fe7c1d (built-in diff: assorted updates, 2006-04-29) claimed to be careful about doing this, but its breakage was hidden because back then "git diff" was still a shell script that did not use the codepath it introduced fully. Signed-off-by: Junio C Hamano <gitster@pobox.com>