aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Call setup_git_directory() much earlierLinus Torvalds2006-07-29
| | | | | | | | | This changes the calling convention of built-in commands and passes the "prefix" (i.e. pathname of $PWD relative to the project root level) down to them. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Call setup_git_directory() earlyLinus Torvalds2006-07-28
| | | | | | | | | | | | | | | Any git command that expects to work in a subdirectory of a project, and that reads the git config files (which is just about all of them) needs to make sure that it does the "setup_git_directory()" call before it tries to read the config file. This means, among other things, that we need to move the call out of "init_revisions()", and into the caller. This does the mostly trivial conversion to do that. Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Display an error from update-ref if target ref name is invalid.Shawn Pearce2006-07-28
| | | | | | | | | | | | | | | | | | | | Alex Riesen (raa.lkml@gmail.com) recently observed that git branch would fail with no error message due to unexpected situations with regards to refs. For example, if .git/refs/heads/gu is a file but "git branch -b refs/heads/gu/fixa HEAD" was invoked by the user it would fail silently due to refs/heads/gu being a file and not a directory. This change adds a test for trying to create a ref within a directory that is actually currently a file, and adds error printing within the ref locking routine should the resolve operation fail. The error printing code probably belongs at this level of the library as other failures within the ref locking, writing and logging code are also currently at this level of the code. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Fix http-fetchJohannes Schindelin2006-07-28
| | | | | | | | With the latest changes in fetch.c, http-fetch crashed accessing write_ref[i], where write_ref was NULL. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* Merge branch 'pb/multi-fetch'Junio C Hamano2006-07-28
|\ | | | | | | | | | | | | | | * pb/multi-fetch: Teach git-http-fetch the --stdin switch Teach git-local-fetch the --stdin switch Make pull() support fetching multiple targets at once Make pull() take some implicit data as explicit arguments
| * Teach git-http-fetch the --stdin switchPetr Baudis2006-07-27
| | | | | | | | | | | | | | Speeds up things quite a lot when fetching tags with Cogito. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * Teach git-local-fetch the --stdin switchPetr Baudis2006-07-27
| | | | | | | | | | | | | | | | This makes it possible to fetch many commits (refs) at once, greatly speeding up cg-clone. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * Make pull() support fetching multiple targets at oncePetr Baudis2006-07-27
| | | | | | | | | | | | | | | | pull() now takes an array of arguments instead of just one of each kind. Currently, no users use the new capability, but that'll change. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * Make pull() take some implicit data as explicit argumentsPetr Baudis2006-07-27
| | | | | | | | | | | | | | | | | | | | | | Currently it's a bit weird that pull() takes a single argument describing the commit but takes the write_ref from a global variable. This makes it take that as a parameter as well, which might be nicer for the libification in the future, but especially it will make for nicer code when we implement pull()ing multiple commits at once. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | Merge branch 'lt/web'Junio C Hamano2006-07-28
|\ \
| * | gitweb.cgi: Centralize printing of the page pathLuben Tuikov2006-07-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Centralize printing of the page path so that if the entity is a blob, we can set the page path to be the link to the HEAD revision of the "raw" blob. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | gitweb.cgi: Show "raw" head of project link even when $hash is not definedLuben Tuikov2006-07-24
| | | | | | | | | | | | | | | | | | | | | | | | Some callers of git_history() do not set $hash of $file_name. Add code to find it, if it is not defined. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | gitweb.cgi: Include direct link to "raw" files from "history"Luben Tuikov2006-07-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In "history" view, the "page_path" is now also a URL link to the "raw" format of the file, which will always give you the latest version in the repository. This is helpful for externally linking files, such that the latest version is always referenced and in "raw" format. Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | gitweb.cgi: Teach git_history() to read hash from $hash_baseLuben Tuikov2006-07-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | Teach git_history() to take its hash argument from the hb parameter, i.e. from $hash_base. Also change all "a=history" actions to pass "hb=" instead of "h=". Signed-off-by: Luben Tuikov <ltuikov@yahoo.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Merge branch 'js/cvs'Junio C Hamano2006-07-28
|\ \ \ | | | | | | | | | | | | | | | | * js/cvs: cvsserver: imitate git-update-ref when committing
| * | | cvsserver: imitate git-update-ref when committingJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git-update-ref writes into the lockfile, and renames it afterwards. Like commit v1.3.0-rc3~22, it is not only cleaner, but also helps with shared setups: every developer can have a different primary group; what matters is that $GIT_DIR/refs/heads has to be writable by a group you are in. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Merge branch 'js/alias-p'Junio C Hamano2006-07-28
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | * js/alias-p: git wrapper: add --git-dir=<path> and --bare options Allow an alias to start with "-p"
| * | | | git wrapper: add --git-dir=<path> and --bare optionsJohannes Schindelin2006-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With this, you can say git --bare repack -a -d inside a bare repository, and it will actually work. While at it, also move the --version, --help and --exec-path options to the handle_options() function. While at documenting the new options, also document the --paginate option. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | | Allow an alias to start with "-p"Johannes Schindelin2006-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now, something like [alias] pd = -p diff works as expected. [jc: a follow-up fix from Jeff King folded in.] Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | Merge branch 'jc/diff'Junio C Hamano2006-07-28
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | * jc/diff: git-diff A...B to (usually) mean "git-diff `git-merge-base A B` B"
| * | | | | git-diff A...B to (usually) mean "git-diff `git-merge-base A B` B"Junio C Hamano2006-07-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This tweaks the argument parser of "git diff" to allow "git-diff A...B" to show diffs leading to B since their merge-base, when there is only one sensible merge base between A and B. Currently nonsense cases are thrown at combined-diff to produce nonsense results, which would eventually need to be fixed. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | t4103: fix binary patch application test.Junio C Hamano2006-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The generated binary patch was _not_ binary -- earlier I made the --full-index flag to imply binary patch generation to the diff machinery, but later we made it independent from --binary (although the latter implies the former). Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | git-apply -R: binary patches are irreversible for now.Junio C Hamano2006-07-28
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | Teach git-apply about '-R'Johannes Schindelin2006-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | Makefile: ssh-pull.o depends on ssh-fetch.cJohannes Schindelin2006-07-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | log and diff family: honor config even from subdirectoriesJunio C Hamano2006-07-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There currently is an unfortunate circular dependency between what init_revisions (the command line revision specification parser) does and setting up the log and diff options. The function uses setup_git_directory() to find the root of the project relative to the current directory and calls diff_setup() to prepare diff generation. However, some of the things that diff_setup() does needs to depend on the configuration variable, which needs to be read after setup_git_directory() is called. This patch is a low impact workaround. It first lets init_revisions() to run and do its thing, then uses git_config() and diff_setup() after it returns, so that configuration variables that affects the diff operation can be used from subdirectories. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | git-reset: detect update-ref error and report it.Junio C Hamano2006-07-27
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | | lost-found: use fsck-objects --fullJunio C Hamano2006-07-27
| |_|_|_|/ |/| | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | mailinfo: accept >From in message headerMichael S. Tsirkin2006-07-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Mail I get sometimes has multiple From lines, like this: From Majordomo@vger.kernel.org Thu Jul 27 16:39:36 2006 >From mtsirkin Thu Jul 27 16:39:36 2006 Received: from yok.mtl.com [10.0.8.11] ... which confuses git-mailinfo since that does not recognize >From as a valid header line. This patch makes it recognize >From XXX as a valid header line. Signed-off-by: Michael S. Tsirkin <mst@mellanox.co.il> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | Remove -d from *-fetch usage stringsPetr Baudis2006-07-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a really ancient remnant of the short era of delta objects stored directly in the object database. Signed-off-by: Petr Baudis <pasky@suse.cz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | daemon: documentation for --reuseaddr, --detach and --pid-fileMatthias Lederhofer2006-07-27
| |_|/ / |/| | | | | | | | | | | | | | | Signed-off-by: Matthias Lederhofer <matled@gmx.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | instaweb: Be more clear if httpd or the browser failJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Merge branch 'pb/configure'Junio C Hamano2006-07-26
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | * pb/configure: Rename man1 and man7 variables to man1dir and man7dir Allow INSTALL, bindir, mandir to be set in main Makefile
| * | | | Rename man1 and man7 variables to man1dir and man7dirJakub Narebski2006-06-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch renames man1 and man7 variables to man1dir and man7dir, according to "Makefile Conventions: Variables for Installation Directories" in make.info of GNU Make. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | | Allow INSTALL, bindir, mandir to be set in main MakefileJakub Narebski2006-06-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Makefiles in subdirectories now use existing value of INSTALL, bindir, mandir if it is set, allowing those to be set in main Makefile or in included config.mak. Main Makefile exports variables which it sets. Accidentally it renames bin to bindir in Documentation/Makefile (should be bindir from start, but is unused, perhaps to be removed). Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | git-cvsserver: support multiline commit messagesJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Earlier, cvsserver barfed when you tried to check in files with a multiline commit message. That is what Argumentx is for... Argument: lines can be followed by several Argumentx: lines, which means they should be appended. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | t7001: add test for git-mv dir1 dir2/Johannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If dir2 already exists, git-mv should move dir1 _into_dir2/. Noticed by Jon Smirl. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | gitweb: fix two warningsJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These warnings cluttered up my log. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | git-instaweb: respect bindir from MakefileJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Not everybody installs git to /usr/bin/git. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | git-instaweb: some Apache have mod_cgi builtinJohannes Schindelin2006-07-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So test for it, and do not always try to load mod_cgi.o. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | t4112: simplify the test and remove unneeded working tree file.Junio C Hamano2006-07-26
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | Extend testing git-mv for renaming of subdirectoriesJosef Weidendorfer2006-07-26
| |_|/ / |/| | | | | | | | | | | | | | | Signed-off-by: Josef Weidendorfer <Josef.Weidendorfer@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | cvsserver: avoid warning about active db handlesv1.4.2-rc2Johannes Schindelin2006-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Turns out that DBD::SQLite does not favour preparing statements which are never executed. So, turn all 4 statements, which were prepared _always_, into methods, like the other 12 prepared statements. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | cvsserver: suppress warningsJohannes Schindelin2006-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch defines $state->{prependdir} as the empty string, so that quite a few warnings are avoided. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Acked-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Substitute xmalloc()+memset(0) with xcalloc().Peter Eriksen2006-07-25
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Peter Eriksen <s022018@student.dtu.dk> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | gitweb: escape tag commentsDaniel Drake2006-07-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I have a tag with a comment which includes an & character. Firefox wouldn't display my gitweb summary page due to malformed XML. This solves the problem. Signed-off-by: Daniel Drake <dsd@gentoo.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Merge branch 'jc/clone-bind-failure'Junio C Hamano2006-07-25
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * jc/clone-bind-failure: fetch/clone: check return status from ls-remote
| * | | | fetch/clone: check return status from ls-remoteJunio C Hamano2006-07-13
| | | | | | | | | | | | | | | | | | | | Some callers of ls-remote did not check its return status.
* | | | | Merge branch 'jt/format-patch'Junio C Hamano2006-07-25
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * jt/format-patch: builtin-log: typefix for recent format-patch changes. Add option to set initial In-Reply-To/References Add option to enable threading headers git-format-patch: Make the second and subsequent mails replies to the first
| * | | | | builtin-log: typefix for recent format-patch changes.Junio C Hamano2006-07-14
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>