aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Add case insensitivity support for directories when using git statusJoshua Jensen2010-10-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using a case preserving but case insensitive file system, directory case can differ but still refer to the same physical directory. git status reports the directory with the alternate case as an Untracked file. (That is, when mydir/filea.txt is added to the repository and then the directory on disk is renamed from mydir/ to MyDir/, git status shows MyDir/ as being untracked.) Support has been added in name-hash.c for hashing directories with a terminating slash into the name hash. When index_name_exists() is called with a directory (a name with a terminating slash), the name is not found via the normal cache_name_compare() call, but it is found in the slow_same_name() function. Additionally, in dir.c, directory_exists_in_index_icase() allows newly added directories deeper in the directory chain to be identified. Ultimately, it would be better if the file list was read in case insensitive alphabetical order from disk, but this change seems to suffice for now. The end result is the directory is looked up in a case insensitive manner and does not show in the Untracked files list. Signed-off-by: Joshua Jensen <jjensen@workspacewhiz.com> Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Case insensitivity support for .gitignore via core.ignorecaseJoshua Jensen2010-10-06
| | | | | | | | | | | | | | | | | | | | | | This is especially beneficial when using Windows and Perforce and the git-p4 bridge. Internally, Perforce preserves a given file's full path including its case at the time it was added to the Perforce repository. When syncing a file down via Perforce, missing directories are created, if necessary, using the case as stored with the filename. Unfortunately, two files in the same directory can have differing cases for their respective paths, such as /diRa/file1.c and /DirA/file2.c. Depending on sync order, DirA/ may get created instead of diRa/. It is possible to handle directory names in a case insensitive manner without this patch, but it is highly inconvenient, requiring each character to be specified like so: [Bb][Uu][Ii][Ll][Dd]. With this patch, the gitignore exclusions honor the core.ignorecase=true configuration setting and make the process less error prone. The above is specified like so: Build Signed-off-by: Joshua Jensen <jjensen@workspacewhiz.com> Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Add string comparison functions that respect the ignore_case variable.Joshua Jensen2010-10-06
| | | | | | | | | | | | | | | | | | | Multiple locations within this patch series alter a case sensitive string comparison call such as strcmp() to be a call to a string comparison call that selects case comparison based on the global ignore_case variable. Behaviorally, when core.ignorecase=false, the *_icase() versions are functionally equivalent to their C runtime counterparts. When core.ignorecase=true, the *_icase() versions perform a case insensitive comparison. Like Linus' earlier ignorecase patch, these may ignore filename conventions on certain file systems. By isolating filename comparisons to certain functions, support for those filename conventions may be more easily met. Signed-off-by: Joshua Jensen <jjensen@workspacewhiz.com> Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile & configure: add a NO_FNMATCH_CASEFOLD flagÆvar Arnfjörð Bjarmason2010-10-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On some platforms (like Solaris) there is a fnmatch, but it doesn't support the GNU FNM_CASEFOLD extension that's used by the jj/icase-directory series' fnmatch_icase wrapper. Change the Makefile so that it's now possible to set NO_FNMATCH_CASEFOLD=YesPlease on those systems, and add a configure probe for it. Unlike the NO_REGEX check we don't add AC_INCLUDES_DEFAULT to our headers. This is because on a GNU system the definition of FNM_CASEFOLD in fnmatch.h is guarded by: #if !defined _POSIX_C_SOURCE || _POSIX_C_SOURCE < 2 || defined _GNU_SOURCE One of the headers AC_INCLUDES_DEFAULT includes ends up defining one of those, so if we'd use it we'd always get NO_FNMATCH_CASEFOLD=YesPlease on GNU systems, even though they have FNM_CASEFOLD. When checking the flags we use: ifdef NO_FNMATCH ... else ifdef NO_FNMATCH_CASEFOLD ... endif endif The "else" so that we don't link against compat/fnmatch/fnmatch.o twice if both NO_FNMATCH and NO_FNMATCH_CASEFOLD are defined. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile & configure: add a NO_FNMATCH flagÆvar Arnfjörð Bjarmason2010-10-06
| | | | | | | | | | | | | | Windows and MinGW both lack fnmatch() in their C library and needed compat/fnmatch, but they had duplicate code for adding the compat function, and there was no Makefile flag or configure check for fnmatch. Change the Makefile it so that it's now possible to compile the compat function with a NO_FNMATCH=YesPlease flag, and add a configure probe for it. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* git-svn: fix fetch with deleted tagDavid D. Kilzer2010-08-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently git-svn assumes that two tags created from the same revision will have the same repo url, so it uses a ref to the tag without checking that its url matches the current url. This causes issues when fetching an svn repo where a tag was created, deleted, and then recreated under the following circumstances: - Both tags were copied from the same revision. - Both tags had the same name. - Both tags had different repository paths. - [Optional] Both tags have a file with the same name but different content. When all four conditions are met, a checksum mismatch error occurs because the content of two files with the same path differs (see t/t9155--git-svn-fetch-deleted-tag.sh): Checksum mismatch: ChangeLog 065854.... expected: ce771b.... got: 9563fd.... When only the first three conditions are met, no error occurs but the tag in git matches the first (deleted) tag instead of the last (most recent) tag (see t/t9156-git-svn-fetch-deleted-tag-2.sh). The fix is to verify that the repo url for the ref matches the current url. If the urls do not match, then a "tail" is grown on the tag name by appending a dash and rechecking the new ref's repo url until either a matching repo url is found or a new tag is created. Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
* git-svn: fix regex to remove "tail" from svn tagsDavid D. Kilzer2010-08-15
| | | | | | | | | | | Fix a regular expression used to remove the revision from the end of an svn tag or branch name. The regex did not account for any "tail" (dashes) that may have been added to the end of the tag name (which first appeared in v1.4.1-rc2~11). If not fixed, tags with names like "tags/mytag@5--@2" may be created. Signed-off-by: David D. Kilzer <ddkilzer@kilzer.net> Acked-by: Eric Wong <normalperson@yhbt.net>
* Merge branch 'jc/sha1-name-find-fix'Junio C Hamano2010-08-12
|\ | | | | | | | | | | | | | | * jc/sha1-name-find-fix: sha1_name.c: fix parsing of ":/token" syntax Conflicts: sha1_name.c
| * sha1_name.c: fix parsing of ":/token" syntaxJunio C Hamano2010-08-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The parser tried to clean up the object flags it used while finding commits with matching string, but was not doing a very good job at it. This caused "checkout -b new ':/token'", which internally tries to parse ':/token' twice as an object name, to fail when the commit in question was reachable from only one ref. The mask bits given to pop_most_recent_commit(&list, MASK) means "I have already been on the list to be processed, so please do not place me again even if I am found to be a parent of some other commit on the list." So mark them when we add them to the list at the beginning. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'jn/doc-pull'Junio C Hamano2010-08-12
|\ \ | | | | | | | | | | | | * jn/doc-pull: Documentation: flesh out “git pull” description
| * | Documentation: flesh out “git pull” descriptionJonathan Nieder2010-08-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current description in the pull man page does not say much more than that “git pull” is fetch + merge. Though that is all a person needs to know in the end, it would be useful to summarize a bit about what those commands do for new readers. Most of this description is taken from the “git merge” docs. Now that we explain how to back out of a failed merge (reset --merge), we can tone down the warning against that a bit. Except, as Thomas noticed, there’s a risk with that because people might read this version of the manpage online and then conclude that it is safe to try a merge with uncommitted changes, only to find that their “git reset” doesn't support --merge yet. Or worse, verify that their git-reset has --merge by a quick test (1b5b465 is in 1.6.2) but then find that it does not help with backing out of a merge (e11d7b5 is only in 1.7.0!). So keep the warning. With clarifications from Ævar, Thomas, and Junio. Noticed-by: Geoff Russell <geoffrey.russell@gmail.com> Cc: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Cc: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'jn/maint-gitweb-dynconf'Junio C Hamano2010-08-12
|\ \ \ | | | | | | | | | | | | | | | | * jn/maint-gitweb-dynconf: gitweb: allow configurations that change with each request
| * | | gitweb: allow configurations that change with each requestJonathan Nieder2010-08-02
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gitolite's contrib/gitweb/gitweb.conf includes: $ENV{GL_USER} = $cgi->remote_user || "gitweb"; which is useful for setups where a user has to be authenticated to access certain repos. Perhaps other typical configurations change per session in other ways, too. v1.7.2-rc2~6 (gitweb: Move evaluate_gitweb_config out of run_request, 2010-07-05) broke such configurations for a speedup, by loading the configuration once per FastCGI process. Probably in the end there should be a way to specify in the configuration whether a particular installation wants the speedup or the flexibility. But for now it is easier to just undo the relevant change. This partially reverts commit 869d58813b24c74e84c9388041eafcef40cb51e4. Reported-by: Julio Lajara <julio.lajara@alum.rpi.edu> Analysis-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'bc/use-more-hardlinks-in-install'Junio C Hamano2010-08-12
|\ \ \ | | | | | | | | | | | | | | | | | | | | * bc/use-more-hardlinks-in-install: Makefile: make hard/symbolic links for non-builtins too Makefile: link builtins residing in bin directory to main git binary too
| * | | Makefile: make hard/symbolic links for non-builtins tooBrandon Casey2010-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To conserve space/improve file caching we try to make hard or symbolic links from each builtin program to the main git executable rather than having each be a complete duplicate copy of it. We weren't doing this for the non-builtin programs though. So, just because we can, and because it's easy, and for completeness sake, let's do it. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Makefile: link builtins residing in bin directory to main git binary tooBrandon Casey2010-07-25
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To conserve space/improve file caching we try to make hard or symbolic links from each builtin program to the main git executable rather than having each be a complete duplicate copy of it. We weren't doing this for the builtin programs residing in the bin directory though. So, let's do so. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | Merge branch 'tr/rfc-reset-doc'Junio C Hamano2010-08-12
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tr/rfc-reset-doc: Documentation/reset: move "undo permanently" example behind "make topic" Documentation/reset: reorder examples to match description Documentation/reset: promote 'examples' one section up Documentation/reset: separate options by mode Documentation/git-reset: reorder modes for soft-mixed-hard progression
| * | | Documentation/reset: move "undo permanently" example behind "make topic"Thomas Rast2010-07-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | I consider the latter usage more important. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Documentation/reset: reorder examples to match descriptionThomas Rast2010-07-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A previous commit moved the <paths> mode (undoes git-add) to the front in the description, so make the examples follow the same order. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Documentation/reset: promote 'examples' one section upThomas Rast2010-07-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Move the examples section upwards, before the discussion that gives the gory details. Adjust the style of the heading accordingly. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Documentation/reset: separate options by modeThomas Rast2010-07-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove all but -q from the OPTIONS section, and instead explain the options separated by usage mode, since they only apply to one each. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | Documentation/git-reset: reorder modes for soft-mixed-hard progressionThomas Rast2010-07-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reorder the documetation so that the soft/mixed/hard modes are in this order. This way they form a natural progression towards changing more of the state. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'jn/parse-date-basic'Junio C Hamano2010-08-12
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * jn/parse-date-basic: Export parse_date_basic() to convert a date string to timestamp
| * | | | Export parse_date_basic() to convert a date string to timestampJonathan Nieder2010-07-15
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | approxidate() is not appropriate for reading machine-written dates because it guesses instead of erroring out on malformed dates. parse_date() is less convenient since it returns its output as a string. So export the underlying function that writes a timestamp. While at it, change the return value to match the usual convention: return 0 for success and -1 for failure. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Acked-by: Ramkumar Ramachandra <artagnon@gmail.com> Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | Merge branch 'sp/fix-smart-http-deadlock-on-error'Junio C Hamano2010-08-12
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * sp/fix-smart-http-deadlock-on-error: smart-http: Don't deadlock on server failure
| * | | | smart-http: Don't deadlock on server failureShawn O. Pearce2010-08-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the remote HTTP server fails (e.g. returns 404 or 500) when we posted the RPC to it, we won't have sent anything to the background Git process that is supposed to handle the stream. Because we didn't send anything, its waiting for input from remote-curl, and remote-curl cannot read its response payload because doing so would lead to a deadlock. Send the background task EOF on its input before we try to read its response back, that way it will break out of its read loop and terminate. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | Merge branch 'maint'Junio C Hamano2010-08-12
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: push: mention "git pull" in error message for non-fast forwards Standardize do { ... } while (0) style t/t7003: replace \t with literal tab in sed expression index-pack: Don't follow replace refs.
| * | | | | push: mention "git pull" in error message for non-fast forwardsMatthieu Moy2010-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The message remains fuzzy to include "git pull", "git pull --rebase" and others, but directs the user to the simplest solution in the vast majority of cases. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Standardize do { ... } while (0) styleJonathan Nieder2010-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | t/t7003: replace \t with literal tab in sed expressionBrandon Casey2010-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The sed utilities on IRIX and Solaris do not interpret the sequence '\t' to mean a tab character; they read a literal character 't'. So, use a literal tab instead. Signed-off-by: Brandon Casey <casey@nrlssc.navy.mil> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | index-pack: Don't follow replace refs.Nelson Elhage2010-08-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this, attempting to index a pack containing objects that have been replaced results in a fatal error that looks like: fatal: SHA1 COLLISION FOUND WITH <replaced-object> ! Signed-off-by: Nelson Elhage <nelhage@ksplice.com> Acked-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'maint'Junio C Hamano2010-08-11
|\ \ \ \ \ \ | |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: post-receive-email: remove spurious commas in email subject fast-import: export correctly marks larger than 2^20-1 t/lib-git-svn.sh: use $PERL_PATH for perl, not perl from $PATH diff: strip extra "/" when stripping prefix
| * | | | | post-receive-email: remove spurious commas in email subjectMatthieu Moy2010-08-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous form produced subjects like [SCM] project.git branch, foo, updated. ... The new one will produce the lighter [SCM] project.git branch foo updated. ... Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | fast-import: export correctly marks larger than 2^20-1Raja R Harinath2010-08-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | dump_marks_helper() has a bug when dumping marks larger than 2^20-1, i.e., when the sparse array has more than two levels. The bug was that the 'base' counter was being shifted by 20 bits at level 3, and then again by 10 bits at level 2, rather than a total shift of 20 bits in this argument to the recursive call: (base + k) << m->shift There are two ways to fix this correctly, the elegant: (base + k) << 10 and the one I chose due to edit distance: base + (k << m->shift) Signed-off-by: Raja R Harinath <harinath@hurrynot.org> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | t/lib-git-svn.sh: use $PERL_PATH for perl, not perl from $PATHÆvar Arnfjörð Bjarmason2010-08-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change the git-svn tests to use $PERL_PATH, not the "perl" in $PATH. Using perl in $PATH was added by Sam Vilain in v1.6.6-rc0~95^2~3, Philippe Bruhat introduced $PERL_PATH to the test suite in v1.6.6-rc0~9^2, but the lib-git-svn.sh tests weren't updated to use the new convention. This resulted in the git-svn tests always being skipped on my system. My /usr/bin/perl has access to SVN::Core and SVN::Repos, but the perl in my $PATH does not. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | diff: strip extra "/" when stripping prefixJakub Narebski2010-08-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are two ways a user might want to use "diff --relative": 1. For a file in a directory, like "subdir/file", the user can use "--relative=subdir/" to strip the directory. 2. To strip part of a filename, like "foo-10", they can use "--relative=foo-". We currently handle both of those situations. However, if the user passes "--relative=subdir" (without the trailing slash), we produce inconsistent results. For the unified diff format, we collapse the double-slash of "a//file" correctly into "a/file". But for other formats (raw, stat, name-status), we end up with "/file". We can do what the user means here and strip the extra "/" (and only a slash). We are not hurting any existing users of (2) above with this behavior change because the existing output for this case was nonsensical. Patch by Jakub, tests and commit message by Jeff King. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'maint'Junio C Hamano2010-08-09
|\ \ \ \ \ \ | |/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: gitweb: clarify search results page when no matching commit found Documentation: add a FILES section for show-ref Makefile: add missing dependency on http.h Makefile: add missing dependencies on url.h Documentation/git-log: Clarify --full-diff git-rebase: fix typo when parsing --force-rebase imap-send: Fix sprintf usage prune: allow --dry-run for -n and --verbose for -v notes: allow --dry-run for -n and --verbose for -v Document -B<n>[/<m>], -M<n> and -C<n> variants of -B, -M and -C Documentation: cite git-am from git-apply t7003: fix subdirectory-filter test Allow "check-ref-format --branch" from subdirectory check-ref-format: handle subcommands in separate functions pretty-options.txt: match --format's documentation with implementation.
| * | | | | gitweb: clarify search results page when no matching commit foundJonathan Nieder2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When searching commits for a string that never occurs, the results page looks something like this: projects / foo.git / search \o/ summary | ... | tree [commit] search: [ kfjdkas ] [ ]re first ⋅ prev ⋅ next Merge branch 'maint' Foo: a demonstration project Without a list of hits to compare it to, the header describing the commit named by the hash parameter (usually HEAD) may itself look like a hit. Add some text (“No match.”) to replace the empty list of hits and avoid this confusion. While at it, remove some nearby dead code, left behind from a simplification a few years ago (v1.5.4-rc0~276^2~4, 2007-11-01). Noticed-by: Erick Mattos <erick.mattos@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Acked-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Documentation: add a FILES section for show-refJonathan Nieder2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A peek at where the refs are kept might help understanding, even if, as the DESCRIPTION section suggests, direct access is not part of the public API. Balance that out with a pointer to update-ref. Suggested-by: Geoff Russell <geoffrey.russell@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Makefile: add missing dependency on http.hJonathan Nieder2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | v1.7.1-rc0~65^2~2 (http: init and cleanup separately from http-walker, 2010-03-02) introduced a direct dependency from http-fetch on the HTTP request library. Declare it. Detected with "make CHECK_HEADER_DEPENDENCIES=1". Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Acked-by: Tay Ray Chuan <rctay89@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Makefile: add missing dependencies on url.hJonathan Nieder2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | v1.7.2-rc0~56^2 and its parent (decode file:// and ssh:// URLs, 2010-05-23) introduced a new url library. Update the Makefile with the relevant dependencies. Detected with "make CHECK_HEADER_DEPENDENCIES=1". Cc: Jeff King <peff@peff.net> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Documentation/git-log: Clarify --full-diffMichael J Gruber2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current description gives the impression that "--full-diff" affects "log -p" only. Make it clearer that it affects all diff-based output types. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | git-rebase: fix typo when parsing --force-rebaseWilly Tarreau2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to two missing hyphens, The "force" keyword on the command line would be taken as an alias for the --force-rebase option. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | imap-send: Fix sprintf usageÆvar Arnfjörð Bjarmason2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When composing a command for the imap server, imap-send uses a single nfsnprintf() invocation for brevity instead of dealing separately with the case when there is a message to be sent and the case when there isn’t. The unused argument in the second case, while valid, is confusing for static analyzers and human readers. v1.6.4-rc0~117 (imap-send: add support for IPv6, 2009-05-25) mistakenly used %hu as the format for an int “port”, by analogy with existing usage for the unsigned short “addr.sin_port”.  Use %d instead. Noticed with clang. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | prune: allow --dry-run for -n and --verbose for -vRené Scharfe2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For consistency with other git commands, let git prune accept the long options --dry-run and --verbose for the respective short ones -n and -v. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | notes: allow --dry-run for -n and --verbose for -vRené Scharfe2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For consistency with other git commands, let the prune subcommand of git notes accept the long options --dry-run and --verbose for the respective short ones -n and -v. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Document -B<n>[/<m>], -M<n> and -C<n> variants of -B, -M and -CMatthieu Moy2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These options take an optional argument, but this optional argument was not documented. Original patch by Matthieu Moy, but documentation for -B mostly copied from the explanations of Junio C Hamano. While we're there, fix a typo in a comment in diffcore.h. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Documentation: cite git-am from git-applyBrad King2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Users reading git-apply documentation may also be interested in git-am, especially after receiving an email created with git-format-patch. The documentation for git-am already references git-apply. Add the reverse. Signed-off-by: Brad King <brad.king@kitware.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | t7003: fix subdirectory-filter testThomas Rast2010-08-09
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test would not fail if the filtering failed to do anything, since in test -z "$(git diff HEAD directorymoved:newsubdir)"' 'directorymoved:newsubdir' is not valid, so git-diff fails without printing anything on stdout. But then the exit status of git-diff is lost, whereas test -z "" succeeds. Use 'git diff --exit-code' instead, which does the right thing and has the added bonus of showing the differences if there are any. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | Allow "check-ref-format --branch" from subdirectoryJonathan Nieder2010-08-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | check-ref-format --branch requires access to the repository to resolve refs like @{-1}. Noticed by Nguyễn Thái Ngọc Duy. Cc: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>