aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Add 'filter' attribute and external filter driver definition.Junio C Hamano2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | The interface is similar to the custom low-level merge drivers. First you configure your filter driver by defining 'filter.<name>.*' variables in the configuration. filter.<name>.clean filter command to run upon checkin filter.<name>.smudge filter command to run upon checkout Then you assign filter attribute to each path, whose name matches the custom filter driver's name. Example: (in .gitattributes) *.c filter=indent (in config) [filter "indent"] clean = indent smudge = cat Signed-off-by: Junio C Hamano <junkio@cox.net>
* Add 'ident' conversion.Junio C Hamano2007-04-24
| | | | | | | | | | | The 'ident' attribute set to path squashes "$ident:<any bytes except dollor sign>$" to "$ident$" upon checkin, and expands it to "$ident: <blob SHA-1> $" upon checkout. As we have two conversions that affect checkin/checkout paths, clarify how they interact with each other. Signed-off-by: Junio C Hamano <junkio@cox.net>
* Merge branch 'jc/the-index'Junio C Hamano2007-04-24
|\ | | | | | | | | | | * jc/the-index: Make read-cache.c "the_index" free. Move index-related variables into a structure.
| * Make read-cache.c "the_index" free.Junio C Hamano2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | This makes all low-level functions defined in read-cache.c to take an explicit index_state structure as their first parameter, to specify which index to work on. These functions traditionally operated on "the_index" and were named foo_cache(); the counterparts this patch introduces are called foo_index(). The traditional foo_cache() functions are made into macros that give "the_index" to their corresponding foo_index() functions. Signed-off-by: Junio C Hamano <junkio@cox.net>
| * Move index-related variables into a structure.Junio C Hamano2007-04-22
| | | | | | | | | | | | | | | | | | This defines a index_state structure and moves index-related global variables into it. Currently there is one instance of it, the_index, and everybody accesses it, so there is no code change. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | Merge branch 'mk/diff'Junio C Hamano2007-04-24
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | * mk/diff: Diff between two blobs should take mode changes into account now. use mode of the tree in git-diff, if <tree>:<file> syntax is used store mode in rev_list, if <tree>:<filename> syntax is used add add_object_array_with_mode add get_sha1_with_mode Add S_IFINVALID mode
| * | Diff between two blobs should take mode changes into account now.Junio C Hamano2007-04-24
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | use mode of the tree in git-diff, if <tree>:<file> syntax is usedMartin Koegler2007-04-24
| | | | | | | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | store mode in rev_list, if <tree>:<filename> syntax is usedMartin Koegler2007-04-24
| | | | | | | | | | | | | | | Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | add add_object_array_with_modeMartin Koegler2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | Each object in struct object_array is extended with the mode. If not specified, S_IFINVALID is used. An object with an mode value can be added with add_object_array_with_mode. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | add get_sha1_with_modeMartin Koegler2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | get_sha1_with_mode basically behaves as get_sha1. It has an additional parameter for storing the mode of the object. If the mode can not be determined, it stores S_IFINVALID. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | Add S_IFINVALID modeMartin Koegler2007-04-24
| | | | | | | | | | | | | | | | | | | | | S_IFINVALID is used to signal, that no mode information is available. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Merge branch 'maint'Junio C Hamano2007-04-24
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | * maint: Remove usernames from all commit messages, not just when using svmprops applymbox & quiltimport: typofix. Create a sysconfdir variable, and use it for ETC_GITCONFIG
| * | | Remove usernames from all commit messages, not just when using svmpropsAdam Roben2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Sam Vilain <sam.vilain@catalyst.net.nz> Signed-off-by: Adam Roben <aroben@apple.com> Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | applymbox & quiltimport: typofix.Junio C Hamano2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 6777c380 fixed only one of three typos introduced in an earlier patch 87ab7992. This fixes the other two. Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | Create a sysconfdir variable, and use it for ETC_GITCONFIGJosh Triplett2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ETC_GITCONFIG defaults to $(prefix)/etc/gitconfig, so if you just set prefix=/usr, you end up with a git that looks in /usr/etc/gitconfig, rather than /etc/gitconfig as specified by the FHS. Furthermore, setting ETC_GITCONFIG does not fix the paths to any future system-wide configuration files. Factor out the path to the system-wide configuration directory into a variable sysconfdir, normally set to $(prefix)/etc, but set to /etc when prefix=/usr . This fixes the prefix=/usr problem for ETC_GITCONFIG, and allows centralized configuration of any future system-wide configuration files without requiring further action from package maintainers or other people building and installing git. Signed-off-by: Josh Triplett <josh@freedesktop.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Merge branch 'master' of git://repo.or.cz/git/fastimportJunio C Hamano2007-04-24
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'master' of git://repo.or.cz/git/fastimport: fast-import: size_t vs ssize_t fix importing of subversion tars Don't repack existing objects in fast-import
| * | | | fast-import: size_t vs ssize_tSami Farin2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | size_t is unsigned, so (n < 0) is never true. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | fix importing of subversion tarsUwe Kleine-König2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add a / between the prefix and name fields of the tar archive if prefix is non-empty. Signed-off-by: Uwe Kleine-König <ukleinek@informatik.uni-freiburg.de> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | Don't repack existing objects in fast-importShawn O. Pearce2007-04-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some users of fast-import have been trying to use it to rewrite commits and trees, an activity where the all of the relevant blobs are already available from the existing packfiles. In such a case we don't want to repack a blob, even if the frontend application has supplied us the raw data rather than a mark or a SHA-1 name. I'm intentionally only checking the packfiles that existed when fast-import started and am always ignoring all loose object files. We ignore loose objects because fast-import tends to operate on a very large number of objects in a very short timespan, and it is usually creating new objects, not reusing existing ones. In such a situtation the majority of the objects will not be found in the existing packfiles, nor will they be loose object files. If the frontend application really wants us to look at loose object files, then they can just repack the repository before running fast-import. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | | | | gitattributes documentation: clarify overridingJunio C Hamano2007-04-24
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | | t/test-lib.sh: Protect ourselves from common misconfigurationJunio C Hamano2007-04-24
| |_|/ / |/| | | | | | | | | | | | | | | | | | | that exports CDPATH to the environment Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Merge branch 'maint'Junio C Hamano2007-04-24
|\ \ \ \ | | |/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Documentation/git-reset.txt: suggest git commit --amend in example. Build RPM with ETC_GITCONFIG=/etc/gitconfig Ignore all man sections as they are generated files. Fix typo in git-am: s/Was is/Was it/ Reverse the order of -b and --track in the man page. dir.c(common_prefix): Fix two bugs Conflicts: git.spec.in
| * | | Documentation/git-reset.txt: suggest git commit --amend in example.Gerrit Pape2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | In example 'Undo a commit and redo', refer to 'git commit --amend', as this is the easier alternative. Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | Build RPM with ETC_GITCONFIG=/etc/gitconfigJunio C Hamano2007-04-23
| | | | | | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | Ignore all man sections as they are generated files.Brian Gernhardt2007-04-23
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Brian Gernhardt <benji@silverinsanity.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | Fix typo in git-am: s/Was is/Was it/Josh Triplett2007-04-23
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Josh Triplett <josh@freedesktop.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | Reverse the order of -b and --track in the man page.Brian Gernhardt2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Using "-b --track newbranch oldbranch" gives the error: git checkout: updating paths is incompatible with switching branches/forcing However, "--track -b ..." works just fine. Signed-off-by: Brian Gernhardt <benji@silverinsanity.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
| * | | dir.c(common_prefix): Fix two bugsJohannes Schindelin2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The function common_prefix() is used to find the common subdirectory of a couple of pathnames. When checking if the next pathname matches up with the prefix, it incorrectly checked the whole path, not just the prefix (including the slash). Thus, the expensive part of the loop was executed always. The other bug is more serious: if the first and the last pathname in the list have a longer common prefix than the common prefix for _all_ pathnames in the list, the longer one would be chosen. This bug was probably hidden by the fact that bash's wildcard expansion sorts the results, and the code just so happens to work with sorted input. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | git-fetch: Fix "argument list too long"OGAWA Hirofumi2007-04-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If $ls_remote_result was too long, git-fetch--tool -s pick-rref "$rref" "$ls_remote_result" in git-fetch will fail with "argument list too long". This patch fixes git-fetch--tool and git-fetch by passing $ls_remote_result via stdin. Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Add clean.requireForce option, and add -f option to git-clean to override itJosh Triplett2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a new configuration option clean.requireForce. If set, git-clean will refuse to run, unless forced with the new -f option, or not acting due to -n. Signed-off-by: Josh Triplett <josh@freedesktop.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | t6030: grab commit object name as we goJunio C Hamano2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of running rev-list and picking earlier lines using head/tail pipeline, grab commit object name as we build commits. This also removes a non POSIX use of tail with -linenum (more posixly-correct way to say it is "-n linenum") Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | t5302: avoid using tail -cJunio C Hamano2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | A Large Angry SCM (gitzilla) noticed that on an unnamed platform, tail -c wants its byte count as part of the option, not as a separate argument. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | t4201: Do not display weird characters on the terminalJohannes Schindelin2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that git-commit got chatty, we have to shut it up again. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | add file checkout progressNicolas Pitre2007-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is nice to see what is happening when checking out large amount of files, either with git-checkout or git-reset. The new progress code already decides what is a "significant amount" and displays progress only in that case.. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | | Document "diff=driver" attributeJunio C Hamano2007-04-23
| |_|/ |/| | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | gitweb: Show "no difference" message for empty diffv1.5.2-rc0Martin Koegler2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, gitweb shows only header and footer, if no differences are found. This patch adds a "No differences found" message for the html output. Signed-off-by: Martin Koegler <mkoegler@auto.tuwien.ac.at> Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | delay progress display when checking out filesNicolas Pitre2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | Let's start displaying progress only if more than 50% of total number of files remains to be checked out after 2 seconds. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | provide a facility for "delayed" progress reportingNicolas Pitre2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | This allows for progress to be displayed only if the progress has not reached a specified percentage treshold within a given delay in seconds. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | make progress "title" part of the common progress interfaceNicolas Pitre2007-04-22
| | | | | | | | | | | | | | | | | | | | | If the progress bar ends up in a box, better provide a title for it too. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | common progress display supportNicolas Pitre2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of having this code duplicated in multiple places, let's have a common interface for progress display. If someday someone wishes to display a cheezy progress bar instead then only one file will have to be changed. Note: I left merge-recursive.c out since it has a strange notion of progress as it apparently increase the expected total number as it goes. Someone with more intimate knowledge of what that is supposed to mean might look at converting it to the common progress interface. Signed-off-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Support 'diff=pgm' attributeJunio C Hamano2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enhances the attributes mechanism so that external programs meant for existing GIT_EXTERNAL_DIFF interface can be specifed per path. To configure such a custom diff driver, first define a custom diff driver in the configuration: [diff "my-c-diff"] command = <<your command string comes here>> Then mark the paths that you want to use this custom driver using the attribute mechanism. *.c diff=my-c-diff The intent of this separation is that the attribute mechanism is used for specifying the type of the contents, while the configuration mechanism is used to define what needs to be done to that type of the contents, which would be specific to both platform and personal taste. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | pack-objects: make generated packfile read-onlyJunio C Hamano2007-04-22
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Update tests not to assume that generated packfiles are writable.Junio C Hamano2007-04-22
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Fix 'quickfix' on pack-objects.Junio C Hamano2007-04-22
| | | | | | | | | | | | | | | | | | | | | The earlier quickfix forced world-readable permission bits. This updates it to honor umask and core.sharedrepository settings. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | pack-objects: quickfix for permission modes.Junio C Hamano2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | mkstemp() often creates the file in 0600 which means the resulting packfile is not readable by anybody other than the repository owner. Force 0644 for now, even though this is not strictly correct. Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Fix crash in t0020 (crlf conversion)Alex Riesen2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reallocated wrong size. Noticed on Ubuntu 7.04 probably because it has some malloc diagnostics in libc: "git-read-tree --reset -u HEAD" aborted in the test. Valgrind sped up the debugging greatly: took me 10 minutes. Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Fix a typo in crlf conversion codeAlex Riesen2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | Also, noticed by valgrind: the code caused a read out-of-bounds. Some comments updated as well (they still reflected old calling conventions). Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Cleanup variables in cat-fileShawn O. Pearce2007-04-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I want to add new command line options to cat-file, but to do that we need to change how we handle argv[] first. This is a simple cleanup that assigns names to the two arguments we currently care about. Signed-off-by: Shawn O. Pearce <spearce@spearce.org> Signed-off-by: Junio C Hamano <junkio@cox.net>
* | | Update draft release notes for v1.5.2Junio C Hamano2007-04-22
| | | | | | | | | | | | Signed-off-by: Junio C Hamano <junkio@cox.net>