summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-03-07Move local variables to narrower scopesLibravatar Benjamin Kramer4-12/+8
These weren't used outside and can be safely moved Signed-off-by: Benjamin Kramer <benny.kra@googlemail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07Remove unused function scope local variablesLibravatar Benjamin Kramer8-27/+9
These variables were unused and can be removed safely: builtin-clone.c::cmd_clone(): use_local_hardlinks, use_separate_remote builtin-fetch-pack.c::find_common(): len builtin-remote.c::mv(): symref diff.c::show_stats():show_stats(): total diffcore-break.c::should_break(): base_size fast-import.c::validate_raw_date(): date, sign fsck.c::fsck_tree(): o_sha1, sha1 xdiff-interface.c::parse_num(): read_some Signed-off-by: Benjamin Kramer <benny.kra@googlemail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07MinGW: fix diff --no-index /dev/null ...Libravatar Johannes Schindelin2-1/+5
When launching "diff --no-index" with a parameter "/dev/null", the MSys bash converts the "/dev/null" to a "nul", which usually makes sense. But Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07git-p4: remove tabs from usermap fileLibravatar Pete Wyckoff1-1/+1
Some users have tabs in their names, oddly enough. This causes problems when loading the usercache from disk, as split separates the fields on the wrong tabs. When fast-import's parse_ident() tries to parse the committer field, it is unhappy about the unbalanced <..> angle brackets. It is easy enough to convert the tabs to single spaces. Signed-off-by: Pete Wyckoff <pw@padd.com> Acked-by: Simon Hausmann <simon@lst.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07Add an (optional, since expensive) test for >2gb clonesLibravatar Johannes Schindelin1-0/+45
Define GIT_TEST_CLONE_2GB=t if you want the test not to be skipped. The test works by constructing a repository larger than 2gb, and then cloning it. The repository is forced larger than 2gb by setting compression and delta depth to zero, and then adding just enough unique objects of a given size. The objects consist of a running decimal number in ASCII, padded by spaces. Should that break in the future, e.g. when pack v4 becomes default, there is a commented-out call to test-genrandom which can be substituted, but that uses more cycles than the current method. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07bash completion: teach fetch, pull, and push to complete their optionsLibravatar Jay Soffian1-5/+56
fetch, pull, and push didn't know their options. They do now. merge's options are factored into a variable so they can be shared between _git_merge and _git_pull Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07bash completion: refactor --strategy completionLibravatar Jay Soffian1-18/+20
The code to complete --strategy was duplicated between _git_rebase and _git_merge, and is about to gain a third caller (_git_pull). This patch factors it into its own function. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07bash completion: fix completion issues with fetch, pull, and pushLibravatar Jay Soffian1-49/+60
Sverre Rabbelier noticed a completion issue with push: $ git push ori<tab> git push origin $ git push -f ori<tab> git push -f origin/ Markus Heidelberg pointed out that the issue extends to fetch and pull. The reason is that the current code naively assumes that if COMP_CWORD=2, it should complete a remote name, otherwise it should complete a refspec. This assumption fails if there are any --options. This patch fixes that issue by instead scanning COMP_CWORDS to see if the remote has been completed yet (we now assume the first non-dashed argument is the remote). The new logic is factored into a function, shared by fetch, pull, and push. The new function also properly handles '.' as the remote. Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-07Brown paper bag fix for MinGW 64-bit statLibravatar Johannes Schindelin1-1/+1
When overriding the identifier "stat" so that "struct stat" will be substituted with "struct _stati64" everywhere, I tried to fix the calls to the _function_ stat(), too, but I forgot to change the earlier attempt "stat64" to "_stati64" there. So, the stat() calls were overridden by calls to _stati64() instead. Unfortunately, there is a function _stati64() so that I missed that calls to stat() were not actually overridden by calls to mingw_lstat(), but t4200-rerere.sh showed the error. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-06Update draft release notes to 1.6.3Libravatar Junio C Hamano1-0/+60
2009-03-05Merge branch 'en/maint-hash-object'Libravatar Junio C Hamano1-2/+2
* en/maint-hash-object: Ensure proper setup of git_dir for git-hash-object Conflicts: hash-object.c
2009-03-05Merge branch 'jc/blame'Libravatar Junio C Hamano1-64/+43
* jc/blame: blame: show "previous" information in --porcelain/--incremental format git-blame: refactor code to emit "porcelain format" output
2009-03-05Merge branch 'ns/pretty-format'Libravatar Junio C Hamano6-9/+85
* ns/pretty-format: bash completion: add --format= and --oneline options for "git log" Add tests for git log --pretty, --format and --oneline. Add --oneline that is a synonym to "--pretty=oneline --abbrev-commit" Give short-hands to --pretty=tformat:%formatstring Add --format that is a synonym to --pretty
2009-03-05Merge branch 'jk/sane-relative-time'Libravatar Junio C Hamano1-1/+19
* jk/sane-relative-time: never fallback relative times to absolute
2009-03-05Merge branch 'fc/config-editor'Libravatar Junio C Hamano2-4/+18
* fc/config-editor: git config: trivial cleanup for editor action git config: codestyle cleanups config: Add new option to open an editor.
2009-03-05Merge branch 'js/send-email'Libravatar Junio C Hamano3-151/+479
* js/send-email: send-email: add --confirm option and configuration setting send-email: don't create temporary compose file until it is needed send-email: --suppress-cc improvements send-email: handle multiple Cc addresses when reading mbox message send-email: allow send-email to run outside a repo
2009-03-05Merge branch 'sg/rerere-cleanup'Libravatar Junio C Hamano3-29/+20
* sg/rerere-cleanup: rerere: remove duplicated functions
2009-03-05Merge branch 'jc/add-p-unquote'Libravatar Junio C Hamano2-10/+52
* jc/add-p-unquote: git-add -i/-p: learn to unwrap C-quoted paths
2009-03-05Merge branch 'jw/imap-preformatted-html'Libravatar Junio C Hamano2-0/+60
* jw/imap-preformatted-html: imap.preformattedHTML to tell Thunderbird to send non-flowed text
2009-03-05Merge branch 'jw/format-patch-attach'Libravatar Junio C Hamano2-2/+28
* jw/format-patch-attach: Enable setting attach as the default in .gitconfig for git-format-patch.
2009-03-05Merge branch 'sr/force-rebase'Libravatar Junio C Hamano1-5/+19
* sr/force-rebase: Teach rebase to rebase even if upstream is up to date
2009-03-05Merge branch 'fg/exclude-bq'Libravatar Junio C Hamano2-2/+9
* fg/exclude-bq: Support "\" in non-wildcard exclusion entries
2009-03-05Merge branch 'dm/add-i-edit-abort'Libravatar Junio C Hamano1-0/+4
* dm/add-i-edit-abort: add -i: revisit hunk on editor failure
2009-03-05Merge branch 'tp/completion'Libravatar Junio C Hamano1-38/+42
* tp/completion: Fixup: Add bare repository indicator for __git_ps1 Add bare repository indicator for __git_ps1 completion: More fixes to prevent unbound variable errors completion: Better __git_ps1 support when not in working directory completion: Use consistent if [...] convention, not "test" completion: For consistency, change "git rev-parse" to __gitdir calls
2009-03-05Merge branch 'js/branch-symref'Libravatar Junio C Hamano2-32/+160
* js/branch-symref: add basic branch display tests branch: clean up repeated strlen Avoid segfault with 'git branch' when the HEAD is detached builtin-branch: improve output when displaying remote branches Conflicts: builtin-branch.c
2009-03-05Merge branch 'al/ansi-color'Libravatar Junio C Hamano6-43/+51
* al/ansi-color: builtin-branch.c: Rename branch category color names Clean up use of ANSI color sequences
2009-03-05Merge branch 'js/valgrind'Libravatar Junio C Hamano7-5/+301
* js/valgrind: valgrind: do not require valgrind 3.4.0 or newer test-lib: avoid assuming that templates/ are in the GIT_EXEC_PATH Tests: let --valgrind imply --verbose and --tee Add a script to coalesce the valgrind outputs t/Makefile: provide a 'valgrind' target test-lib.sh: optionally output to test-results/$TEST.out, too Valgrind support: check for more than just programming errors valgrind: ignore ldso and more libz errors Add valgrind support in test scripts
2009-03-05MinGW: 64-bit file offsetsLibravatar Johannes Schindelin2-4/+9
The type 'off_t' should be used everywhere so that the bit-depth of that type can be adjusted in the standard C library, and you just need to recompile your program to benefit from the extended precision. Only that it was not done that way in the MS runtime library. This patch reroutes off_t to off64_t and provides the other necessary changes so that finally, clones larger than 2 gigabyte work on Windows (provided you are on a file system that allows files larger than 2gb). Initial patch by Sickboy <sb@dev-heaven.net>. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Johannes Sixt <j6t@kdbg.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-05Documentation - More examples for git bisectLibravatar John Tapsell1-1/+17
Including passing parameters to the programs, and running more complicated checks without requiring a seperate shell script. Signed-off-by: John Tapsell <johnflux@gmail.com> Acked-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-05Draft release notes: Carry forward the warning for behaviour changesLibravatar Junio C Hamano1-0/+22
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Merge branch 'maint'Libravatar Junio C Hamano1-2/+2
* maint: Make the 'lock file' exists error more informative
2009-03-04improve missing repository error messageLibravatar Jeff King4-4/+4
Certain remote commands, when asked to do something in a particular directory that was not actually a git repository, would say "unable to chdir or not a git archive". The "chdir" bit is an unnecessary detail, and the term "git archive" is much less common these days than "git repository". So let's switch them all to: fatal: '%s' does not appear to be a git repository Signed-off-by: Jeff King <peff@peff.net> Acked-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Make the 'lock file' exists error more informativeLibravatar John Tapsell1-2/+2
It looks like someone did 90% of the work, then forgot to actually use the function in one place. Also the helper function did not use the correct variable. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04git-archive: add --output=<file> to send output to a fileLibravatar Carlos Manuel Duclos Vergara3-0/+31
When archiving a repository there is no way to specify a file as output. This patch adds a new option "--output" that redirects the output to a file instead of stdout. Signed-off-by: Carlos Manuel Duclos Vergara <carlos.duclos@nokia.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Improve error message for git-filter-branchLibravatar John Tapsell1-1/+3
Tell the user that a backup (original) already exists, and how to solve this problem (with -f option) Signed-off-by: John Tapsell <johnflux@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Google has renamed the imap folderLibravatar John Tapsell1-0/+10
Also add a comment that the web interface wraps the lines Signed-off-by: John Tapsell <johnflux@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Modify description file to say what this file isLibravatar John Tapsell2-3/+5
A lot of people see this message for the first time on the gitweb interface, where there is no clue as to what 'this file' means. Signed-off-by: John Tapsell <johnflux@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04rev-list: estimate number of bisection step leftLibravatar Christian Couder2-3/+44
This patch teaches "git rev-list --bisect-vars" to output an estimate of the number of bisection step left _after the current one_ along with the other variables it already outputs. This patch also makes "git-bisect.sh" display this number of steps left _after the current one_, along with the estimate of the number of revisions left to test (after the current one). Here is a table to help analyse what should be the best estimate for the number of bisect steps left. N : linear case --> probabilities --> best ------------------------------------------------------------- 1 : G-B --> 0 --> 0 2 : G-U1-B --> 0 --> 0 3 : G-U1-U2-B --> 0(1/3) 1(2/3) --> 1 4 : G-U1-U2-U3-B --> 1 --> 1 5 : G-U1-U2-U3-U4-B --> 1(3/5) 2(2/5) --> 1 6 : G-U1-U2-U3-U4-U5-B --> 1(2/6) 2(4/6) --> 2 7 : G-U1-U2-U3-U4-U5-U6-B --> 1(1/7) 2(6/7) --> 2 8 : G-U1-U2-U3-U4-U5-U6-U7-B --> 2 --> 2 9 : G-U1-U2-U3-U4-U5-U6-U7-U8-B --> 2(7/9) 3(2/9) --> 2 10: G-U1-U2-U3-U4-U5-U6-U7-U8-U9-B --> 2(6/10)3(4/10)--> 2 In the column "N", there is the number of revisions that could _now_ be the first bad commit we are looking for. The "linear case" column describes the linear history corresponding to the number in column N. G means good, B means bad, and Ux means unknown. Note that the first bad revision we are looking for can be any Ux or B. In the "probabilities" column, there are the different outcomes in number of steps with the odds of each outcome in parenthesis corresponding to the linear case. The "best" column gives the most accurate estimate among the different outcomes in the "probabilities" column. We have the following: best(2^n) == n - 1 and for any x between 0 included and 2^n excluded, the probability for n - 1 steps left looks like: P(2^n + x) == (2^n - x) / (2^n + x) and P(2^n + x) < 0.5 means 2^n < 3x So the algorithm used in this patch calculates 2^n and x, and then choose between returning n - 1 and n. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Fix neglect of diff_setup()/diff_setup_done() symmetry.Libravatar Keith Cascio1-0/+2
Code that calls diff_setup(), including via init_revisions(), should later call diff_setup_done(), possibly via setup_revisions(). Failure to do so could cause errors, especially in the future when we add responsibilities to diff_setup_done(). This instance causes no known errors with the present code. But it resulted in an error with an experimental patch. Signed-off-by: Keith Cascio <keith@cs.ucla.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Use DIFF_XDL_SET/DIFF_OPT_SET instead of raw bit-maskingLibravatar Keith Cascio2-7/+13
Signed-off-by: Keith Cascio <keith@cs.ucla.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-04Beginning of 1.6.3 development trackLibravatar Junio C Hamano3-1/+29
2009-03-04Beginning of 1.6.2 maintenance trackLibravatar Junio C Hamano2-1/+7
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-03GIT 1.6.2Libravatar Junio C Hamano3-7/+6
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-03Documentation: Typo / spelling / formatting fixesLibravatar Mike Ralphson3-4/+4
Signed-off-by: Mike Ralphson <mike@abacus.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-03Documentation: Expand a couple of abbreviationsLibravatar Mike Ralphson1-1/+1
These may not be obvious to non-native English speakers Signed-off-by: Mike Ralphson <mike@abacus.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-03Documentation: Typos / spelling fixes in RelNotesLibravatar Mike Ralphson4-6/+6
Signed-off-by: Mike Ralphson <mike@abacus.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-03Documentation/git-archive.txt: Note attributesLibravatar Roy Lee1-0/+17
Signed-off-by: Roy Lee <roylee17@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-02send-email: add --confirm option and configuration settingLibravatar Jay Soffian3-39/+174
send-email violates the principle of least surprise by automatically cc'ing additional recipients without confirming this with the user. This patch teaches send-email a --confirm option. It takes the following values: --confirm=always always confirm before sending --confirm=never never confirm before sending --confirm=cc confirm before sending when send-email has automatically added addresses from the patch to the Cc list --confirm=compose confirm before sending the first message when using --compose. (Needed to maintain backwards compatibility with existing behavior.) --confirm=auto 'cc' + 'compose' If sendemail.confirm is unconfigured, the option defaults to 'compose' if any suppress-Cc related options have been used, otherwise it defaults to 'auto'. Unfortunately, it is impossible to introduce this patch such that it helps new users without potentially annoying some existing users. We attempt to mitigate the latter by: * Allowing the user to set 'git config sendemail.confirm never' * Allowing the user to say 'all' after the first prompt to not be prompted on remaining emails during the same invocation. * Telling the user about the 'sendemail.confirm' setting if it is unconfigured whenever we prompt due to Cc before sending. * Only prompting if no --suppress related options have been passed, as using such an option is likely to indicate an experienced send-email user. There is a slight fib in message informing the user of the sendemail.confirm setting and this is intentional. Setting 'auto' differs from leaving sendemail.confirm unset in two ways: 1) 'auto' obviously squelches the informational message; 2) 'auto' prompts when the Cc list has been expanded even in the presence of a --suppress related option, where leaving sendemail.confirm unset does not. This is intentional to keep the message simple, and to avoid adding another sendemail.confirm value ('auto-except-suppress'?). Signed-off-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-02Documentation: minor grammatical fixes.Libravatar David J. Mellor1-13/+13
The final hunk in this patch corrects what appears to be a typo: of --> or Signed-off-by: David J. Mellor <dmellor@whistlingcat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2009-03-02Documentation: minor grammatical fixes.Libravatar David J. Mellor2-6/+6
Signed-off-by: David J. Mellor <dmellor@whistlingcat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>