summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorMatthew Ogilvie <mmogilvi_git@miniinfo.net>2008-05-14 22:35:47 -0600
committerJunio C Hamano <gitster@pobox.com>2008-05-16 12:00:31 -0700
commit8a06a632976ead891115ad9ac9dea7b99c52158e (patch)
tree7e27776b28adcd37d36db97e488c5ac4534136cf /Documentation
parent044182ef82f1a371c469a26a6d64c7b823aea764 (diff)
downloadgit-8a06a632976ead891115ad9ac9dea7b99c52158e.tar.gz
implement gitcvs.usecrlfattr
If gitcvs.usecrlfattr is set to true, git-cvsserver will consult the "crlf" for each file to determine if it should mark the file as binary (-kb). Signed-off-by: Matthew Ogilvie <mmogilvi_git@miniinfo.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/config.txt23
-rw-r--r--Documentation/git-cvsserver.txt26
2 files changed, 38 insertions, 11 deletions
diff --git a/Documentation/config.txt b/Documentation/config.txt
index 217980f48d..036e61e2f6 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -660,11 +660,21 @@ gitcvs.logfile::
Path to a log file where the CVS server interface well... logs
various stuff. See linkgit:git-cvsserver[1].
+gitcvs.usecrlfattr
+ If true, the server will look up the `crlf` attribute for
+ files to determine the '-k' modes to use. If `crlf` is set,
+ the '-k' mode will be left blank, so cvs clients will
+ treat it as text. If `crlf` is explicitly unset, the file
+ will be set with '-kb' mode, which supresses any newline munging
+ the client might otherwise do. If `crlf` is not specified,
+ then 'gitcvs.allbinary' is used. See linkgit:gitattribute[5].
+
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'.
+ If true, all files not otherwise specified using
+ 'gitcvs.usecrlfattr' and an explicitly set or unset `crlf`
+ attribute are sent to the client in mode '-kb'. This
+ causes the client to treat them as binary files which
+ suppresses any newline munging it otherwise might do.
gitcvs.dbname::
Database used by git-cvsserver to cache revision information
@@ -695,8 +705,9 @@ gitcvs.dbTableNamePrefix::
linkgit:git-cvsserver[1] for details). Any non-alphabetic
characters will be replaced with underscores.
-All gitcvs variables except for 'gitcvs.allbinary' can also be
-specified as 'gitcvs.<access_method>.<varname>' (where 'access_method'
+All gitcvs variables except for 'gitcvs.usecrlfattr' and
+'gitcvs.allbinary' can also be specified as
+'gitcvs.<access_method>.<varname>' (where 'access_method'
is one of "ext" and "pserver") to make them apply only for the given
access method.
diff --git a/Documentation/git-cvsserver.txt b/Documentation/git-cvsserver.txt
index b1106714b2..4888b8604d 100644
--- a/Documentation/git-cvsserver.txt
+++ b/Documentation/git-cvsserver.txt
@@ -301,11 +301,27 @@ checkout, diff, status, update, log, add, remove, commit.
Legacy monitoring operations are not supported (edit, watch and related).
Exports and tagging (tags and branches) are not supported at this stage.
-The server should set the '-k' mode to binary when relevant, however,
-this is not really implemented yet. For now, you can force the server
-to set '-kb' for all files by setting the `gitcvs.allbinary` config
-variable. In proper GIT tradition, the contents of the files are
-always respected. No keyword expansion or newline munging is supported.
+CRLF Line Ending Conversions
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+By default the server leaves the '-k' mode blank for all files,
+which causes the cvs client to treat them as a text files, subject
+to crlf conversion on some platforms.
+
+You can make the server use `crlf` attributes to set the '-k' modes
+for files by setting the `gitcvs.usecrlfattr` config variable.
+In this case, if `crlf` is explicitly unset ('-crlf'), then the
+will set '-kb' mode, for binary files. If it `crlf` is set,
+then the '-k' mode will explicitly be left blank. See
+also linkgit:gitattributes[5] for more information about the `crlf`
+attribute.
+
+Alternatively, if `gitcvs.usecrlfattr` config is not enabled
+or if the `crlf` attribute is unspecified for a filename, then
+the server uses the `gitcvs.allbinary` for the default setting.
+If `gitcvs.allbinary` is set, then the files not otherwise
+specified will default to '-kb' mode. Otherwise the '-k' mode
+is left blank.
Dependencies
------------