blob: 0c3ae29ce760a0f0999dbc1e659385c0e4c873c5 [file] [log] [blame]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="generator" content="AsciiDoc 7.0.2" />
<style type="text/css">
/* Debug borders */
p, li, dt, dd, div, pre, h1, h2, h3, h4, h5, h6 {
/*
border: 1px solid red;
*/
}
body {
margin: 1em 5% 1em 5%;
}
a { color: blue; }
a:visited { color: fuchsia; }
em {
font-style: italic;
}
strong {
font-weight: bold;
}
tt {
color: navy;
}
h1, h2, h3, h4, h5, h6 {
color: #527bbd;
font-family: sans-serif;
margin-top: 1.2em;
margin-bottom: 0.5em;
line-height: 1.3;
}
h1 {
border-bottom: 2px solid silver;
}
h2 {
border-bottom: 2px solid silver;
padding-top: 0.5em;
}
div.sectionbody {
font-family: serif;
margin-left: 0;
}
hr {
border: 1px solid silver;
}
p {
margin-top: 0.5em;
margin-bottom: 0.5em;
}
pre {
padding: 0;
margin: 0;
}
span#author {
color: #527bbd;
font-family: sans-serif;
font-weight: bold;
font-size: 1.2em;
}
span#email {
}
span#revision {
font-family: sans-serif;
}
div#footer {
font-family: sans-serif;
font-size: small;
border-top: 2px solid silver;
padding-top: 0.5em;
margin-top: 4.0em;
}
div#footer-text {
float: left;
padding-bottom: 0.5em;
}
div#footer-badges {
float: right;
padding-bottom: 0.5em;
}
div#preamble,
div.tableblock, div.imageblock, div.exampleblock, div.verseblock,
div.quoteblock, div.literalblock, div.listingblock, div.sidebarblock,
div.admonitionblock {
margin-right: 10%;
margin-top: 1.5em;
margin-bottom: 1.5em;
}
div.admonitionblock {
margin-top: 2.5em;
margin-bottom: 2.5em;
}
div.content { /* Block element content. */
padding: 0;
}
/* Block element titles. */
div.title, caption.title {
font-family: sans-serif;
font-weight: bold;
text-align: left;
margin-top: 1.0em;
margin-bottom: 0.5em;
}
div.title + * {
margin-top: 0;
}
td div.title:first-child {
margin-top: 0.0em;
}
div.content div.title:first-child {
margin-top: 0.0em;
}
div.content + div.title {
margin-top: 0.0em;
}
div.sidebarblock > div.content {
background: #ffffee;
border: 1px solid silver;
padding: 0.5em;
}
div.listingblock > div.content {
border: 1px solid silver;
background: #f4f4f4;
padding: 0.5em;
}
div.quoteblock > div.content {
padding-left: 2.0em;
}
div.quoteblock .attribution {
text-align: right;
}
div.admonitionblock .icon {
vertical-align: top;
font-size: 1.1em;
font-weight: bold;
text-decoration: underline;
color: #527bbd;
padding-right: 0.5em;
}
div.admonitionblock td.content {
padding-left: 0.5em;
border-left: 2px solid silver;
}
div.exampleblock > div.content {
border-left: 2px solid silver;
padding: 0.5em;
}
div.verseblock div.content {
white-space: pre;
}
div.imageblock div.content { padding-left: 0; }
div.imageblock img { border: 1px solid silver; }
span.image img { border-style: none; }
dl {
margin-top: 0.8em;
margin-bottom: 0.8em;
}
dt {
margin-top: 0.5em;
margin-bottom: 0;
font-style: italic;
}
dd > *:first-child {
margin-top: 0;
}
ul, ol {
list-style-position: outside;
}
ol.olist2 {
list-style-type: lower-alpha;
}
div.tableblock > table {
border-color: #527bbd;
border-width: 3px;
}
thead {
font-family: sans-serif;
font-weight: bold;
}
tfoot {
font-weight: bold;
}
div.hlist {
margin-top: 0.8em;
margin-bottom: 0.8em;
}
td.hlist1 {
vertical-align: top;
font-style: italic;
padding-right: 0.8em;
}
td.hlist2 {
vertical-align: top;
}
@media print {
div#footer-badges { display: none; }
}
include::./stylesheets/xhtml11-manpage.css[]
/* Workarounds for IE6's broken and incomplete CSS2. */
div.sidebar-content {
background: #ffffee;
border: 1px solid silver;
padding: 0.5em;
}
div.sidebar-title, div.image-title {
font-family: sans-serif;
font-weight: bold;
margin-top: 0.0em;
margin-bottom: 0.5em;
}
div.listingblock div.content {
border: 1px solid silver;
background: #f4f4f4;
padding: 0.5em;
}
div.quoteblock-content {
padding-left: 2.0em;
}
div.exampleblock-content {
border-left: 2px solid silver;
padding-left: 0.5em;
}
</style>
<title>git-cvsserver(1)</title>
</head>
<body>
<div id="header">
<h1>
git-cvsserver(1) Manual Page
</h1>
<h2>NAME</h2>
<div class="sectionbody">
<p>git-cvsserver -
A CVS server emulator for git
</p>
</div>
</div>
<h2>SYNOPSIS</h2>
<div class="sectionbody">
<div class="verseblock">
<div class="content">export CVS_SERVER=git-cvsserver
<em>cvs</em> -d :ext:user@server/path/repo.git co &lt;HEAD_name&gt;</div></div>
</div>
<h2>DESCRIPTION</h2>
<div class="sectionbody">
<p>This application is a CVS emulation layer for git.</p>
<p>It is highly functional. However, not all methods are implemented,
and for those methods that are implemented,
not all switches are implemented.</p>
<p>Testing has been done using both the CLI CVS client, and the Eclipse CVS
plugin. Most functionality works fine with both of these clients.</p>
</div>
<h2>LIMITATIONS</h2>
<div class="sectionbody">
<p>Currently cvsserver works over SSH connections for read/write clients, and
over pserver for anonymous CVS access.</p>
<p>CVS clients cannot tag, branch or perform GIT merges.</p>
</div>
<h2>INSTALLATION</h2>
<div class="sectionbody">
<ol>
<li>
<p>
If you are going to offer anonymous CVS access via pserver, add a line in
/etc/inetd.conf like
</p>
<div class="listingblock">
<div class="content">
<pre><tt> cvspserver stream tcp nowait nobody git-cvsserver pserver
</tt></pre>
</div></div>
<p>Note: In some cases, you need to pass the <em>pserver</em> argument twice for
git-cvsserver to see it. So the line would look like</p>
<div class="listingblock">
<div class="content">
<pre><tt> cvspserver stream tcp nowait nobody git-cvsserver pserver pserver
</tt></pre>
</div></div>
<p>No special setup is needed for SSH access, other than having GIT tools
in the PATH. If you have clients that do not accept the CVS_SERVER
env variable, you can rename git-cvsserver to cvs.</p>
</li>
<li>
<p>
For each repo that you want accessible from CVS you need to edit config in
the repo and add the following section.
</p>
<div class="listingblock">
<div class="content">
<pre><tt> [gitcvs]
enabled=1
# optional for debugging
logfile=/path/to/logfile
</tt></pre>
</div></div>
<p>Note: you need to ensure each user that is going to invoke git-cvsserver has
write access to the log file and to the git repository. When offering anon
access via pserver, this means that the nobody user should have write access
to at least the sqlite database at the root of the repository.</p>
</li>
<li>
<p>
On the client machine you need to set the following variables.
CVSROOT should be set as per normal, but the directory should point at the
appropriate git repo. For example:
</p>
<p>For SSH access, CVS_SERVER should be set to git-cvsserver</p>
<p>Example:</p>
<div class="listingblock">
<div class="content">
<pre><tt> export CVSROOT=:ext:user@server:/var/git/project.git
export CVS_SERVER=git-cvsserver</tt></pre>
</div></div>
</li>
<li>
<p>
For SSH clients that will make commits, make sure their .bashrc file
sets the GIT_AUTHOR and GIT_COMMITTER variables.
</p>
</li>
<li>
<p>
Clients should now be able to check out the project. Use the CVS <em>module</em>
name to indicate what GIT <em>head</em> you want to check out. Example:
</p>
<div class="listingblock">
<div class="content">
<pre><tt> cvs co -d project-master master</tt></pre>
</div></div>
</li>
</ol>
</div>
<h2>Eclipse CVS Client Notes</h2>
<div class="sectionbody">
<p>To get a checkout with the Eclipse CVS client:</p>
<ol>
<li>
<p>
Select "Create a new project -&gt; From CVS checkout"
</p>
</li>
<li>
<p>
Create a new location. See the notes below for details on how to choose the
right protocol.
</p>
</li>
<li>
<p>
Browse the <em>modules</em> available. It will give you a list of the heads in
the repository. You will not be able to browse the tree from there. Only
the heads.
</p>
</li>
<li>
<p>
Pick <em>HEAD</em> when it asks what branch/tag to check out. Untick the
"launch commit wizard" to avoid committing the .project file.
</p>
</li>
</ol>
<p>Protocol notes: If you are using anonymous access via pserver, just select that.
Those using SSH access should choose the <em>ext</em> protocol, and configure <em>ext</em>
access on the Preferences-&gt;Team-&gt;CVS-&gt;ExtConnection pane. Set CVS_SERVER to
<em>git-cvsserver</em>. Not that password support is not good when using <em>ext</em>,
you will definitely want to have SSH keys setup.</p>
<p>Alternatively, you can just use the non-standard extssh protocol that Eclipse
offer. In that case CVS_SERVER is ignored, and you will have to replace
the cvs utility on the server with git-cvsserver or manipulate your .bashrc
so that calling <em>cvs</em> effectively calls git-cvsserver.</p>
</div>
<h2>Clients known to work</h2>
<div class="sectionbody">
<p>CVS 1.12.9 on Debian
CVS 1.11.17 on MacOSX (from Fink package)
Eclipse 3.0, 3.1.2 on MacOSX (see Eclipse CVS Client Notes)
TortoiseCVS</p>
</div>
<h2>Operations supported</h2>
<div class="sectionbody">
<p>All the operations required for normal use are supported, including
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.</p>
<p>The server will set the -k mode to binary when relevant. In proper GIT
tradition, the contents of the files are always respected.
No keyword expansion or newline munging is supported.</p>
</div>
<h2>Dependencies</h2>
<div class="sectionbody">
<p>git-cvsserver depends on DBD::SQLite.</p>
</div>
<h2>Copyright and Authors</h2>
<div class="sectionbody">
<p>This program is copyright The Open University UK - 2006.</p>
<p>Authors: Martyn Smith &lt;martyn@catalyst.net.nz&gt;
Martin Langhoff &lt;martin@catalyst.net.nz&gt;
with ideas and patches from participants of the git-list &lt;git@vger.kernel.org&gt;.</p>
</div>
<h2>Documentation</h2>
<div class="sectionbody">
<p>Documentation by Martyn Smith &lt;martyn@catalyst.net.nz&gt; and Martin Langhoff &lt;martin@catalyst.net.nz&gt; Matthias Urlichs &lt;smurf@smurf.noris.de&gt;.</p>
</div>
<h2>GIT</h2>
<div class="sectionbody">
<p>Part of the <a href="git.html">git(7)</a> suite</p>
</div>
<div id="footer">
<div id="footer-text">
Last updated 15-Jul-2006 01:37:40 UTC
</div>
</div>
</body>
</html>