aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2007-04-14 04:18:46 -0700
committerJunio C Hamano <junkio@cox.net>2007-04-14 04:18:46 -0700
commitedb4fd79ec34254fc4a1c35e8834df4c92cb3bfd (patch)
tree7a983deb4620bc3de0a26d091381b03b35ea8933
parentd016a896d4a58a53dbb98cd85ebd033771413079 (diff)
parent1fa9bf362acbe2c939c246684ab0fe59aec74ba8 (diff)
downloadgit-edb4fd79ec34254fc4a1c35e8834df4c92cb3bfd.tar.gz
git-edb4fd79ec34254fc4a1c35e8834df4c92cb3bfd.tar.xz
Merge branch 'maint'
* maint: git-quiltimport complaining yet still working config.txt: Fix grammatical error in description of http.noEPSV config.txt: Change pserver to server in description of gitcvs.* config.txt: Document core.autocrlf config.txt: Document gitcvs.allbinary Do not default to --no-index when given two directories. Use rev-list --reverse in git-rebase.sh
-rw-r--r--Documentation/config.txt23
-rw-r--r--diff-lib.c36
-rwxr-xr-xgit-quiltimport.sh4
-rwxr-xr-xgit-rebase.sh3
4 files changed, 49 insertions, 17 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt
index cf1e04038..7e41ca6a0 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -117,6 +117,16 @@ core.fileMode::
the working copy are ignored; useful on broken filesystems like FAT.
See gitlink:git-update-index[1]. True by default.
+core.autocrlf::
+ If true, makes git convert `CRLF` at the end of lines in text files to
+ `LF` when reading from the filesystem, and convert in reverse when
+ writing to the filesystem. The variable can be set to
+ 'input', in which case the conversion happens only while
+ reading from the filesystem but files are written out with
+ `LF` at the end of lines. Currently, which paths to consider
+ "text" (i.e. be subjected to the autocrlf mechanism) is
+ decided purely based on the contents.
+
core.symlinks::
If false, symbolic links are checked out as small plain files that
contain the link text. gitlink:git-update-index[1] and
@@ -401,13 +411,20 @@ gc.rerereunresolved::
The default is 15 days. See gitlink:git-rerere[1].
gitcvs.enabled::
- Whether the cvs pserver interface is enabled for this repository.
+ Whether the cvs server interface is enabled for this repository.
See gitlink:git-cvsserver[1].
gitcvs.logfile::
- Path to a log file where the cvs pserver interface well... logs
+ Path to a log file where the cvs server interface well... logs
various stuff. See gitlink:git-cvsserver[1].
+gitcvs.allbinary::
+ If true, all files are sent to the client in mode '-kb'. This
+ causes the client to treat all files as binary files which suppresses
+ any newline munging it otherwise might do. A work-around for the
+ fact that there is no way yet to set single files to mode '-kb'.
+ See gitlink:git-cvsserver[1].
+
http.sslVerify::
Whether to verify the SSL certificate when fetching or pushing
over HTTPS. Can be overridden by the 'GIT_SSL_NO_VERIFY' environment
@@ -445,7 +462,7 @@ http.lowSpeedLimit, http.lowSpeedTime::
http.noEPSV::
A boolean which disables using of EPSV ftp command by curl.
- This can helpful with some "poor" ftp servers which doesn't
+ This can helpful with some "poor" ftp servers which don't
support EPSV mode. Can be overridden by the 'GIT_CURL_FTP_NO_EPSV'
environment variable. Default is false (curl will use EPSV).
diff --git a/diff-lib.c b/diff-lib.c
index 5c5b05bfe..7531e20c7 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -142,18 +142,34 @@ static int queue_diff(struct diff_options *o,
}
}
+/*
+ * Does the path name a blob in the working tree, or a directory
+ * in the working tree?
+ */
static int is_in_index(const char *path)
{
- int len = strlen(path);
- int pos = cache_name_pos(path, len);
- char c;
-
- if (pos < 0)
- return 0;
- if (strncmp(active_cache[pos]->name, path, len))
- return 0;
- c = active_cache[pos]->name[len];
- return c == '\0' || c == '/';
+ int len, pos;
+ struct cache_entry *ce;
+
+ len = strlen(path);
+ while (path[len-1] == '/')
+ len--;
+ if (!len)
+ return 1; /* "." */
+ pos = cache_name_pos(path, len);
+ if (0 <= pos)
+ return 1;
+ pos = -1 - pos;
+ while (pos < active_nr) {
+ ce = active_cache[pos++];
+ if (ce_namelen(ce) <= len ||
+ strncmp(ce->name, path, len) ||
+ (ce->name[len] > '/'))
+ break; /* path cannot be a prefix */
+ if (ce->name[len] == '/')
+ return 1;
+ }
+ return 0;
}
static int handle_diff_files_args(struct rev_info *revs,
diff --git a/git-quiltimport.sh b/git-quiltimport.sh
index edccd8275..018cc75bd 100755
--- a/git-quiltimport.sh
+++ b/git-quiltimport.sh
@@ -73,9 +73,9 @@ mkdir $tmp_dir || exit 2
for patch_name in $(cat "$QUILT_PATCHES/series" | grep -v '^#'); do
echo $patch_name
(cat $QUILT_PATCHES/$patch_name | git-mailinfo "$tmp_msg" "$tmp_patch" > "$tmp_info") || exit 3
- test -s $dotest/patch || {
+ test -s .dotest/patch || {
echo "Patch is empty. Was is split wrong?"
- stop_here $this
+ exit 1
}
# Parse the author information
diff --git a/git-rebase.sh b/git-rebase.sh
index 1d96f3268..2dc2c4fe9 100755
--- a/git-rebase.sh
+++ b/git-rebase.sh
@@ -339,8 +339,7 @@ prev_head=`git-rev-parse HEAD^0`
echo "$prev_head" > "$dotest/prev_head"
msgnum=0
-for cmt in `git-rev-list --no-merges "$upstream"..ORIG_HEAD \
- | @@PERL@@ -e 'print reverse <>'`
+for cmt in `git-rev-list --reverse --no-merges "$upstream"..ORIG_HEAD`
do
msgnum=$(($msgnum + 1))
echo "$cmt" > "$dotest/cmt.$msgnum"