summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2010-04-14diff: add --word-diff option that generalizes --color-wordsThomas Rast
This teaches the --color-words engine a more general interface that supports two new modes: * --word-diff=plain, inspired by the 'wdiff' utility (most similar to 'wdiff -n <old> <new>'): uses delimiters [-removed-] and {+added+} * --word-diff=porcelain, which generates an ad-hoc machine readable format: - each diff unit is prefixed by [-+ ] and terminated by newline as in unified diff - newlines in the input are output as a line consisting only of a tilde '~' Both of these formats still support color if it is enabled, using it to highlight the differences. --color-words becomes a synonym for --word-diff=color, which is the color-only format. Also adds some compatibility/convenience options. Thanks to Junio C Hamano and Miles Bader for good ideas. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-04-03Fix _XOPEN_SOURCE problem on DragonFlyYONETANI Tomokazu
As on FreeBSD, defining _XOPEN_SOURCE to 600 on DragonFly BSD 2.4-RELEASE or later hides symbols from programs, which leads to implicit declaration of functions, making the return value to be assumed an int. On architectures where sizeof(int) < sizeof(void *), this can cause unexpected behaviors or crashes. This change won't affect other OSes unless they define __DragonFly__ macro, or older versions of DragonFly BSD as the current git code doesn't rely on the features only available with _XOPEN_SOURCE set to 600 on DragonFly. Signed-off-by: YONETANI Tomokazu <y0netan1@dragonflybsd.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-04-02builtin/commit: remove unnecessary variable definitionMarkus Heidelberg
The file descriptor is already defined at the beginning of the function. Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-04-02builtin/commit: fix duplicated sentence in a commentMarkus Heidelberg
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-04-02Integrate version 3 ciabot scripts into contrib/.Eric Raymond
These have been extensively live-tested in the last week. The version 2 ciabot.sh maintainer has passed the baton to me; ciabot.py is original. Signed-off-by: Eric S. Raymond <esr@thyrsus.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-04-02Makefile: update defaults for modern CygwinEric Blake
Now that Cygwin 1.7.x has enabled lots of new features, and Cygwin 1.5 is no longer actively supported by the Cygwin mailing lists, we might as well update the defaults to cater to those new features. NO_TRUSTABLE_FILEMODE is only necessary on FAT drives; the Cygwin community recommends NTFS drives, but there is still too much use for FAT to switch the default. Likewise, UNRELIABLE_FSTAT is probably file-system specific, but worth keeping unchanged. This commit does not change the default for NO_MMAP, although definitive proof of whether this option is necessary is lacking. Signed-off-by: Eric Blake <eblake@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Sync with 1.7.0.4Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Git 1.7.0.4v1.7.0.4Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Merge branch 'jc/maint-refs-dangling' into maintJunio C Hamano
* jc/maint-refs-dangling: refs: ref entry with NULL sha1 is can be a dangling symref
2010-03-31Documentation: show-ref <pattern>s are optionalHolger Weiß
Specifying one or more <pattern> parameters is optional when calling show-ref, so mark them as such using brackets in the manual. Signed-off-by: Holger Weiß <holger@zedat.fu-berlin.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Link against libiconv on IRIXHolger Weiß
On IRIX, "-liconv" must be added to the linker command line in order to get iconv(3) support; set the according Makefile variable appropriately. Signed-off-by: Holger Weiß <holger@zedat.fu-berlin.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Don't redefine htonl and ntohl on big-endianHolger Weiß
Since commit 0fcabdeb52b79775173d009ccc179db104dfbb66, compat/bswap.h redefined htonl and ntohl to bswap32 not only if bswap32 has been defined earlier in compat/bswap.h (which is done only on selected platforms), but also if bswap32 has been defined anywhere else. This broke Git at least for NetBSD systems running on big-endian machines (where ntohl and htonl should, of course, be NOOPs), since NetBSD defines a bswap32 macro in the system headers. So, we now undefine any previously defined bswap32 in compat/bswap.h before defining our own. Signed-off-by: Holger Weiß <holger@zedat.fu-berlin.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31gitweb: git_get_project_config requires only $git_dir, not also $projectJakub Narebski
Fix overeager early return in git_get_project_config, introduced in 9be3614 (gitweb: Fix project-specific feature override behavior, 2010-03-01). When git_get_project_config is called from projects list page via git_get_project_owner($path) etc., it is called with $git_dir defined (in git_get_project_owner($path) etc.), but $project variable is not defined. git_get_project_config doesn't use $project variable anyway. Reported-by: Tobias Heinlein <keytoaster@gentoo.org> Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-31Updated the usage string of git resetJan Stępień
Make git reset usage string reflect the command's behaviour and contents of the man page. Signed-off-by: Jan Stępień <jstepien@users.sourceforge.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-30Documentation: Clarify support for smart HTTP backendGreg Bacon
In the description of http.getanyfile, replace the vague "older Git clients" with the earliest release whose client is able to use the upload pack service. Signed-off-by: Greg Bacon <gbacon@dbresearch.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-30Windows: fix utime() for read-only filesJohannes Sixt
Starting with 5256b00 (Use git_mkstemp_mode instead of plain mkstemp to create object files, 2010-02-22) utime() is invoked on read-only files. This is not allowed on Windows and results in many warnings of the form failed utime() on .git/objects/23/tmp_obj_VlgHlc: Permission denied during a repack. Fix it by making the file temporarily writable. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-30diff: fix textconv error zombiesJohannes Sixt
To make the code simpler, run_textconv lumps all of its error checking into one conditional. However, the short-circuit means that an error in reading will prevent us from calling finish_command, leaving a zombie child. Clean up properly after errors. Based-on-work-by: Jeff King <peff@peff.net> Signed-off-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-30Merge branch 'maint'Junio C Hamano
* maint: format-patch: Squelch 'fatal: Not a range." error
2010-03-30format-patch: Squelch 'fatal: Not a range." errorKevin Ballard
Don't output an error on `git format-patch --ignore-if-in-upstream HEAD`. This matches the behavior of `git format-patch HEAD`. Signed-off-by: Kevin Ballard <kevin@sb.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-29Update draft release notes to 1.7.1Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-29Merge branch 'cc/cherry-pick-ff'Junio C Hamano
* cc/cherry-pick-ff: revert: fix tiny memory leak in cherry-pick --ff rebase -i: use new --ff cherry-pick option Documentation: describe new cherry-pick --ff option cherry-pick: add tests for new --ff option revert: add --ff option to allow fast forward when cherry-picking builtin/merge: make checkout_fast_forward() non static parse-options: add parse_options_concat() to concat options
2010-03-29Merge branch 'sb/notes-parse-opt'Junio C Hamano
* sb/notes-parse-opt: notes: rework subcommands and parse options Conflicts: builtin/notes.c
2010-03-29Merge branch 'maint'Junio C Hamano
* maint: Prepare for 1.7.0.4 Conflicts: RelNotes
2010-03-29rebase -i: make post-rewrite work for 'edit'Thomas Rast
The post-rewrite support, in the form of the call to 'record_in_rewritten', was hidden in the arm where we have to record a new commit for the user. This meant that it was never invoked in the case where the user has already amended the commit by herself. [The test is designed to exercise both arms of the 'if' in question.] Furthermore, recording the stopped-sha (the SHA1 of the commit before the editing) suffered from a cut&paste error from die_with_patch and used the wrong variable, hence it never recorded anything. Noticed by Junio. Signed-off-by: Thomas Rast <trast@student.ethz.ch> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-29Prepare for 1.7.0.4Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-29Merge branch 'cp/add-u-pathspec' into maintJunio C Hamano
* cp/add-u-pathspec: test for add with non-existent pathspec git add -u: die on unmatched pathspec
2010-03-29Merge branch 'maint'Junio C Hamano
* maint: t9350: fix careless use of "cd" difftool: Fix '--gui' when diff.guitool is unconfigured fast-export: don't segfault when marks file cannot be opened
2010-03-29t9350: fix careless use of "cd"Junio C Hamano
Upon failure of any of these tests (or when a test that is marked as expecting a failure is fixed), we will end up running later tests in random places. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-28difftool: Fix '--gui' when diff.guitool is unconfiguredDavid Aguilar
When diff.guitool is unconfigured and "--gui" is specified git-difftool dies with the following error message: config diff.guitool: command returned error: 1 Catch the error so that the "--gui" flag is a no-op when diff.guitool is unconfigured. Signed-off-by: David Aguilar <davvid@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-28fast-export: don't segfault when marks file cannot be openedSverre Rabbelier
The error function only prints an error message, resulting in a segfault if we later on try to fprintf to a NULL handle. Fix this by using die_errno instead. Signed-off-by: Sverre Rabbelier <srabbelier@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-28imap-send: suppress warning about cleartext password with CRAM-MD5Chris Webb
If a CRAM-MD5 challenge-response is used to authenticate to the IMAP server, git imap-send shouldn't warn about the password being sent in the clear. Signed-off-by: Chris Webb <chris@arachsys.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-24Merge branch 'jh/maint-submodule-status-in-void'Junio C Hamano
* jh/maint-submodule-status-in-void: git submodule summary: Handle HEAD as argument when on an unborn branch submodule summary: do not fail before the first commit
2010-03-24Merge branch 'tr/notes-display'Junio C Hamano
* tr/notes-display: git-notes(1): add a section about the meaning of history notes: track whether notes_trees were changed at all notes: add shorthand --ref to override GIT_NOTES_REF commit --amend: copy notes to the new commit rebase: support automatic notes copying notes: implement helpers needed for note copying during rewrite notes: implement 'git notes copy --stdin' rebase -i: invoke post-rewrite hook rebase: invoke post-rewrite hook commit --amend: invoke post-rewrite hook Documentation: document post-rewrite hook Support showing notes from more than one notes tree test-lib: unset GIT_NOTES_REF to stop it from influencing tests Conflicts: git-am.sh refs.c
2010-03-24Merge branch 'jl/submodule-diff-dirtiness'Junio C Hamano
* jl/submodule-diff-dirtiness: git status: ignoring untracked files must apply to submodules too git status: Fix false positive "new commits" output for dirty submodules Refactor dirty submodule detection in diff-lib.c git status: Show detailed dirty status of submodules in long format git diff --submodule: Show detailed dirty status of submodules
2010-03-24Merge branch 'pb/log-first-parent-p-m'Junio C Hamano
* pb/log-first-parent-p-m: show --first-parent/-m: do not default to --cc show -c: show patch text revision: introduce setup_revision_opt t4013: add tests for log -p -m --first-parent git log -p -m: document -m and honor --first-parent
2010-03-24Merge branch 'jc/maint-refs-dangling'Junio C Hamano
* jc/maint-refs-dangling: refs: ref entry with NULL sha1 is can be a dangling symref
2010-03-24Merge branch 'maint'Junio C Hamano
* maint: Documentation: explain the meaning of "-g" in git-describe output
2010-03-24Merge branch 'jc/color-attrs' into maintJunio C Hamano
* jc/color-attrs: color: allow multiple attributes
2010-03-24Merge branch 'jk/maint-add-ignored-dir' into maintJunio C Hamano
* jk/maint-add-ignored-dir: tests for "git add ignored-dir/file" without -f dir: fix COLLECT_IGNORED on excluded prefixes t0050: mark non-working test as such
2010-03-24Merge branch 'bg/apply-fix-blank-at-eof' into maintJunio C Hamano
* bg/apply-fix-blank-at-eof: t3417: Add test cases for "rebase --whitespace=fix" t4124: Add additional tests of --whitespace=fix apply: Allow blank context lines to match beyond EOF apply: Remove the quick rejection test apply: Don't unnecessarily update line lengths in the preimage
2010-03-24Documentation: explain the meaning of "-g" in git-describe outputMarkus Heidelberg
Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-22Sync with Git 1.7.0.3Junio C Hamano
* maint: Git 1.7.0.3 .mailmap: Map the the first submissions of MJG by e-mail Documentation/git-clone: Transform description list into item list Documentation/urls: Remove spurious example markers Documentation/gitdiffcore: Remove misleading date in heading Documentation/git-reflog: Fix formatting of command lists
2010-03-22Git 1.7.0.3v1.7.0.3Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-22Merge branch 'maint-1.6.6' into maintJunio C Hamano
* maint-1.6.6: Documentation/git-clone: Transform description list into item list Documentation/urls: Remove spurious example markers Documentation/gitdiffcore: Remove misleading date in heading Documentation/git-reflog: Fix formatting of command lists
2010-03-21.mailmap: Map the the first submissions of MJG by e-mailMichael J Gruber
so that git shortlog with '-e' coalesces all my commits. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-21Documentation/git-clone: Transform description list into item listMichael J Gruber
so that the list of examples is formatted in the same way as for git-fetch, and, more importantly, the different identation for the code blocks in the examples (compared to the immediately preceding code blocks from url.txt) doesn't look like misformatted, but is clarified by the items' bullets. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-21Documentation/urls: Remove spurious example markersMichael J Gruber
In urls.txt (which is included from git-{clone,fetch,push}.txt) several item lists are surrounded by example block markers. This is problematic for two reasons: - None of these lists are example lists, so they should not be marked as such semantically. - The html output looks weird (bulleted list with left sidebar). Therefore, remove the example block markers. Output by the man backend is unaffected. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-21Documentation/gitdiffcore: Remove misleading date in headingMichael J Gruber
Ever since the automatic conversion into man form, the heading contained a misidentified subheading reading "June 2005". Remove this since the documentation is more recent, and the correct date is in the footer. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-21Documentation/git-reflog: Fix formatting of command listsMichael J Gruber
A misplaced list continuation mark appears literally in the rendered doc. Fix this by removing it. Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2010-03-21revert: fix tiny memory leak in cherry-pick --ffJonathan Nieder
We forgot to free defmsg when returning early for a fast-forward. Fixing this should reduce noise during test suite runs with valgrind. More importantly, once cherry-pick learns to pick multiple commits, the amount of memory leaked would start to add up. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>