Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2008-07-15restore legacy behavior for read_sha1_file()Nicolas Pitre
Since commit 8eca0b47ff1598a6d163df9358c0e0c9bd92d4c8, it is possible for read_sha1_file() to return NULL even with existing objects when they are corrupted. Previously a corrupted object would have terminated the program immediately, effectively making read_sha1_file() return NULL only when specified object is not found. Let's restore this behavior for all users of read_sha1_file() and provide a separate function with the ability to not terminate when bad objects are encountered. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15bash: Add long option completion for 'git send-email'Teemu Likonen
Add the following long options to be completed with 'git send-email': --bcc --cc --cc-cmd --chain-reply-to --compose --dry-run --envelope-sender --from --identity --in-reply-to --no-chain-reply-to --no-signed-off-by-cc --no-suppress-from --no-thread --quiet --signed-off-by-cc --smtp-pass --smtp-server --smtp-server-port --smtp-ssl --smtp-user --subject --suppress-cc --suppress-from --thread --to Short ones like --to and --cc are not usable for actual completion because of the shortness itself and because there are longer ones which start with same letters (--thread, --compose). It's still useful to have these shorter options _listed_ when user presses TAB key after typing two dashes. It gives user an idea what options are available (and --to and --cc are probably the most commonly used). Signed-off-by: Teemu Likonen <tlikonen@iki.fi> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15git-submodule - register submodule URL if adding in placeMark Levedahl
When adding a new submodule in place, meaning the user created the submodule as a git repo in the superproject's tree first, we don't go through "git submodule init" to register the module. Thus, the submodule's origin repository URL is not stored in .git/config, and no subsequent submodule operation will ever do so. In this case, assume the URL the user supplies to "submodule add" is the one that should be registered, and do so. Signed-off-by: Mark Levedahl <mlevedahl@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15git-submodule - make "submodule add" more strict, and document itMark Levedahl
This change makes "submodule add" much more strict in the arguments it takes, and is intended to address confusion as recently noted on the git-list. With this change, the required syntax is: $ git submodule add URL path Specifically, this eliminates the form $ git submodule add URL which was confused by more than one person as $ git submodule add path With this patch, the URL locating the submodule's origin repository can be either an absolute URL, or (if it begins with ./ or ../) can express the submodule's repository location relative to the superproject's origin. This patch also eliminates a third form of URL, which was relative to the superproject's top-level directory (not its repository). Any URL that was neither absolute nor matched ./*|../* was assumed to point to a subdirectory of the superproject as the location of the submodule's origin repository. This URL form was confusing and does not seem to correspond to an important use-case. Specifically, no-one has identified the need to clone from a repository already in the superproject's tree, but if this is needed it is easily done using an absolute URL: $(pwd)/relative-path. So, no functionality is lost with this patch. (t6008-rev-list-submodule.sh did rely upon this relative URL, fixed by using $(pwd).) Following this change, there are exactly four variants of submodule-add, as both arguments have two flavors: URL can be absolute, or can begin with ./|../ and thus names the submodule's origin relative to the superproject's origin. Note: With this patch, "submodule add" discerns an absolute URL as matching /*|*:*: e.g., URL begins with /, or it contains a :. This works for all valid URLs, an absolute path in POSIX, as well as an absolute path on Windows). path can either already exist as a valid git repo, or will be cloned from the given URL. The first form here eases creation of a new submodule in an existing superproject as the submodule can be added and tested in-tree before pushing to the public repository. However, the more usual form is the second, where the repo is cloned from the given URL. This specifically addresses the issue of $ git submodule add a/b/c attempting to clone from a repository at "a/b/c" to create a new module in "c". This also simplifies description of "relative URL" as there is now exactly *one* form: a URL relative to the parent's origin repo. Signed-off-by: Mark Levedahl <mlevedahl@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15git-svn: typofixFrederik Schwarzer
Signed-off-by: Frederik Schwarzer <schwarzerf@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15git-svn: find-rev and rebase for SVN::Mirror repositoriesJoão Abecasis
find-rev and rebase error out on svm because git-svn doesn't trace the original svn revision numbers back to git commits. The updated test case, included in the patch, shows the issue and passes with the rest of the patch applied. This fixes Git::SVN::find_by_url to find branches based on the svm:source URL, where useSvmProps is set. Also makes sure cmd_find_rev and working_head_info use the information they have to correctly track the source repository. This is enough to get find-rev and rebase working. Signed-off-by: João Abecasis <joao@abecasis.name> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15tutorial: clarify "pull" is "fetch + merge"Junio C Hamano
The document says that a fetch with a configured remote stores what are fetched in the remote tracking branches "Unlike the longhand form", but there is no longhand form "fetch" demonstrated earlier. This adds a missing demonstration of the longhand form, and a new paragraph to explain why some people might want to fetch before pull. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-15tutorial: use prompt with user names in example, to clarify who is doing whatIan Katz
Signed-off-by: Ian Katz <ifreecarve@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Update draft release notes for 1.6.0Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Merge branch 'sp/maint-bash-completion-optim'Junio C Hamano
* sp/maint-bash-completion-optim: bash completion: Don't offer "a.." as a completion for "a." bash completion: Improve responsiveness of git-log completion
2008-07-14bash completion: Don't offer "a.." as a completion for "a."Shawn O. Pearce
If the user is trying to complete "v1.5.3.<tab>" to see all of the available maintenance releases for 1.5.3 we should not give them an extra dot as the completion. Instead if the user wants a ".." or a "..." operator they should key the two dots out on their own. Its the same number of keystrokes either way. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14git-request-pull: replace call to deprecated peek-remoteRamsay Jones
Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Make rebase--interactive use OPTIONS_SPECStephan Beyer
Also add some checks that --continue/--abort/--skip actions are used without --onto, -p, -t, etc. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14t3404: test two "preserve merges with -p" casesStephan Beyer
There are two cases for preserving merges: 1. The merge base is outside the trunk that is to be rebased. Then commits of those other parents must not be picked. 2. The merge base is inside the trunk that is to be rebased. Then all the commits related to that merge must be picked and the merge must be redone. The "preserve merges with -p" test case tested for case 1 only. This patch adds case 2. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14git-am/git-mailsplit: correct synopsis for reading from stdinStephan Beyer
Invoking git-am or git-mailsplit without mbox or Maildir results in reading an mbox from stdin. Mention this in the synopsis and usage strings. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Merge branch 'maint' to sync with 1.5.6.3Junio C Hamano
* maint: GIT 1.5.6.3 git-am: Do not exit silently if committer is unset t0004: fix timing bug git-mailinfo: document the -n option Fix backwards-incompatible handling of core.sharedRepository
2008-07-14GIT 1.5.6.3v1.5.6.3Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-14Merge branch 'ph/parseopt-step-blame'Junio C Hamano
* ph/parseopt-step-blame: revisions: refactor handle_revision_opt into parse_revision_opt. git-shortlog: migrate to parse-options partially. git-blame: fix lapsus git-blame: migrate to incremental parse-option [2/2] git-blame: migrate to incremental parse-option [1/2] revisions: split handle_revision_opt() from setup_revisions() parse-opt: add PARSE_OPT_KEEP_ARGV0 parser option. parse-opt: fake short strings for callers to believe in. parse-opt: do not print errors on unknown options, return -2 intead. parse-opt: create parse_options_step. parse-opt: Export a non NORETURN usage dumper. parse-opt: have parse_options_{start,end}. git-blame --reverse builtin-blame.c: allow more than 16 parents builtin-blame.c: move prepare_final() into a separate function. rev-list --children revision traversal: --children option
2008-07-14Merge branch 'am/stash-branch'Junio C Hamano
* am/stash-branch: Add a test for "git stash branch" Implement "git stash branch <newbranch> <stash>"
2008-07-14Merge branch 'sg/stash-k-i'Junio C Hamano
* sg/stash-k-i: Documentation: tweak use case in "git stash save --keep-index" stash: introduce 'stash save --keep-index' option
2008-07-14Merge branch 'jc/report-tracking'Junio C Hamano
* jc/report-tracking: branch -r -v: do not spit out garbage stat_tracking_info(): clear object flags used during counting git-branch -v: show the remote tracking statistics git-status: show the remote tracking statistics Refactor "tracking statistics" code used by "git checkout"
2008-07-14Merge branch 'js/pick-root'Junio C Hamano
* js/pick-root: Allow cherry-picking root commits
2008-07-14Merge branch 'ab/bundle'Junio C Hamano
* ab/bundle: Teach git-bundle to read revision arguments from stdin like git-rev-list.
2008-07-14Merge branch 'tr/add-i-e'Junio C Hamano
* tr/add-i-e: git-add--interactive: manual hunk editing mode git-add--interactive: remove hunk coalescing git-add--interactive: replace hunk recounting with apply --recount
2008-07-13git-am: Do not exit silently if committer is unsetStephan Beyer
Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-13bash completion: Improve responsiveness of git-log completionShawn O. Pearce
Junio noticed the bash completion has been taking a long time lately. Petr Baudis tracked it down to 72e5e989b ("bash: Add space after unique command name is completed."). Tracing the code showed we spent significant time inside of this loop within __gitcomp, due to the string copying overhead. [28.146109654] _git common over [28.164791148] gitrefs in [28.280302268] gitrefs dir out [28.300939737] gitcomp in [28.308378112] gitcomp pre-case * [28.313407453] gitcomp iter in * [28.701270296] gitcomp iter out [28.713370786] out normal Since __git_refs avoids this string copying by forking and using echo we use the same trick here when we need to finish generating the names for the caller. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-12t0004: fix timing bugJunio C Hamano
The test created an initial commit, made .git/objects unwritable and then exercised various codepaths to create loose commit, tree and blob objects to make sure the commands notice failures from these attempts. However, the initial commit was not preceded with test_tick, which made its object name depend on the timestamp. The names of all the later tree and blob objects the test tried to create were static. If the initial commit's object name happened to begin with the same two hexdigits as the tree or blob objects the test later attempted to create, the fan-out directory in which these tree or blob would be created is already created when the initial commit was made, and the object creation succeeds, and commands being tested should not notice any failure --- in short, the test was bogus. This makes the fan-out directories also unwritable, and adds test_tick before the commit object creation to make the test repeatable. The contents of the file to create a blob from "a" to "60" is to force the name of the blob object to begin with "1b", which shares the fan-out directory with the initial commit that is created with the test. This was useful when diagnosing the breakage of this test. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-12git-mailinfo: document the -n optionLukas Sandström
Signed-off-by: Lukas Sandström <lukass@etek.chalmers.se> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-12Fix backwards-incompatible handling of core.sharedRepositoryPetr Baudis
06cbe85 (Make core.sharedRepository more generic, 2008-04-16) broke the traditional setting of core.sharedRepository to true, which was to make the repository group writable: with umask 022, it would clear the permission bits for 'other'. (umask 002 did not exhibit this behaviour since pre-chmod() check in adjust_shared_perm() fails in that case.) The call to adjust_shared_perm() should only loosen the permission. If the user has umask like 022 or 002 that allow others to read, the resulting files should be made readable and writable by group, without restricting the readability by others. This patch fixes the adjust_shared_perm() mode tweak based on Junio's suggestion and adds the appropriate tests to t/t1301-shared-repo.sh. Cc: Heikki Orsila <heikki.orsila@iki.fi> Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10apply: fix copy/rename breakageJunio C Hamano
7ebd52a (Merge branch 'dz/apply-again', 2008-07-01) taught "git-apply" to grok a (non-git) patch that is a concatenation of separate patches that touch the same file number of times, by recording the postimage of patch application of previous round and using it as the preimage for later rounds. This "incremental" mode of patch application fundamentally contradicts with the way git rename/copy patches are designed. When a git patch talks about a file A getting modified, and a new file B created out of A, like this: diff --git a/A b/A --- a/A +++ b/A ... change text here ... diff --git a/A b/B copy from A copy to B --- a/A +++ b/B ... change text here ... the second change to produce B does not depend on what is done to A with the first change in any way. This is explicitly done so for reviewability of individual patches. With this commit, we do not look at 'fn_table' that records the postimage of previous round when applying a patch to produce a new file out of an existing file. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10Merge branch 'jk/pager-config'Junio C Hamano
* jk/pager-config: Allow per-command pager config
2008-07-10Merge branch 'js/apply-root'Junio C Hamano
* js/apply-root: git-apply --directory: make --root more similar to GNU diff apply --root: thinkofix. Teach "git apply" to prepend a prefix with "--root=<root>"
2008-07-10Merge branch 'jc/reflog-expire'Junio C Hamano
* jc/reflog-expire: Make default expiration period of reflog used for stash infinite Per-ref reflog expiry configuration
2008-07-10git-send-email: Fix authenticating on some servers when using TLS.Robert Shearman
Send HELO again after a successful STARTTLS command to refresh the list of extensions. These may be different to what is returned over a clear connection (for example the AUTH command may be accepted over a secure connection, but not over a clear connection). Furthermore, this behaviour is recommended by RFC 2487 (http://www.ietf.org/rfc/rfc2487.txt). Signed-off-by: Robert Shearman <robertshearman@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10revisions: refactor handle_revision_opt into parse_revision_opt.Pierre Habouzit
It seems we're using handle_revision_opt the same way each time, have a wrapper around it that does the 9-liner we copy each time instead. handle_revision_opt can be static in the module for now, it's always possible to make it public again if needed. Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10git-shortlog: migrate to parse-options partially.Pierre Habouzit
Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10git-blame: fix lapsusPierre Habouzit
Signed-off-by: Pierre Habouzit <madcoder@debian.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10Provide fallback definitions of PRIu32 and PRIx32Johannes Sixt
Since 6e1c23442 we make use of these C99 constructs, but this commit did not provide fallbacks for non-C99 systems. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10t9100-git-svn-basic.sh: Fix determination of utf-8 localeRamsay Jones
When setting the GIT_SVN_LC_ALL variable, default to the $LANG environment variable, when the $LC_ALL override is not set. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10t9113-*.sh: provide user feedback when test skippedRamsay Jones
Currently this test simply exits without providing any feedback at all. Tell user if the test is being skipped and provide a hint as to how the test may be enabled. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-10Merge branch 'sp/maint-pack-memuse'Junio C Hamano
* sp/maint-pack-memuse: Correct pack memory leak causing git gc to try to exceed ulimit Conflicts: sha1_file.c
2008-07-10Correct pack memory leak causing git gc to try to exceed ulimitShawn O. Pearce
When recursing to unpack a delta base we must unuse_pack() so that the pack window for the current object does not remain pinned in memory while the delta base is itself being unpacked and materialized for our use. On a long delta chain of 50 objects we may need to access 6 different windows from a very large (>3G) pack file in order to obtain all of the delta base content. If the process ulimit permits us to map/allocate only 1.5G we must release windows during this recursion to ensure we stay within the ulimit and transition memory from pack cache to standard malloc, or other mmap needs. Inserting an unuse_pack() call prior to the recursion allows us to avoid pinning the current window, making it available for garbage collection if memory runs low. This has been broken since at least before 1.5.1-rc1, and very likely earlier than that. Its fixed now. :) Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Merge branch 'maint'Junio C Hamano
* maint: Start preparing release notes for 1.5.6.3 git-submodule - Fix bugs in adding an existing repo as a module bash: offer only paths after '--' Remove unnecessary pack-*.keep file after successful git-clone make deleting a missing ref more quiet
2008-07-09Start preparing release notes for 1.5.6.3Junio C Hamano
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Documentation: update sections on naming revisions and revision rangesJunio C Hamano
Various *_HEAD pseudo refs were not documented in any central place. Especially since we may be teaching rebase and am to record ORIG_HEAD, it would be a good time to do so. While at it, reword the explanation on r1..r2 notation to reduce confusion. Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Tone down warning about GNU Interactive ToolsJunio C Hamano
The mention of 1997 was correct when it was made, and it still is true to some extent (http://savannah.gnu.org/forum/forum.php?forum_id=5189 says it has not been actively maintained for quite some time). However, because its name changed not to conflict with us, it is no longer relevant whether many users use gnuit or have moved away to graphical file managers. The only people possibly affected are people who have older version of gnuit installed as "git". Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Avoid apache complaining about lack of server's FQDNMike Hommey
On some setups, apache will say: apache2: Could not reliably determine the server's fully qualified domain name, using $(IP_address) for ServerName Avoid this message polluting tests output by setting a ServerName in apache configuration. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Skip t5540-http-push test when USE_CURL_MULTI is undefinedMike Hommey
When USE_CURL_MULTI is undefined, git http-push doesn't work, so it's useless to test it. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Fix http-push testMike Hommey
http-push test has been broken by 4a7aaccd adding a space character in the place where the test is being run. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
2008-07-09Catch failures from t5540-http-pushMike Hommey
git http-push doesn't handle packed-refs, and now the new builtin-clone created packed refs, the http-push test fails. Mark the current failure as such, and also catch third test's failure that went unreported because git push doesn't return an error code when it says: No refs in common and none specified; doing nothing. Which it does when http-push can't get a list of refs recursively from $URL/refs/. Signed-off-by: Mike Hommey <mh@glandium.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>