Progress:
TIER 2 · MODULE 33· Intermediate

git cvsserver

Pretend to be CVS so old clients can pull.

🎯 What & why

Serve a Git repo as a fake CVS server so legacy clients can pull from it. Niche bridge for shops still wedded to CVS tooling.

🧠 Mental model

A pserver-shaped facade over Git that speaks just enough CVS to satisfy old clients. Read-mostly: write support exists but is fragile and best avoided.

🛠️ Synopsis

git cvsserver [<options>] [pserver|server] [<directory> ...]

Typically launched from xinetd/inetd as the pserver command. Authenticates
against ~/.cvspasswd, then maps a Git repo into a CVS-shaped namespace.
Requires SQLite (default) or another DBI backend to cache state.

🎚️ Switches & options

FlagWhat it does
--base-path <path>Strip prefix from CVS module paths so clients see clean module names.
--strict-pathsRefuse to serve directories outside the path list passed on the command line.
--export-allServe every Git repo found, not just those with the magic export marker.
-V, --versionPrint version and exit.
--export-marks <file>Write the internal commit-to-CVS-rev mapping out for inspection.
--no-strict-paths⚠️ Allow clients to escape the served directory list. Almost never what you want on a public box.

📦 Subcommands

pserver — Run as a CVS pserver (the typical xinetd invocation).
git cvsserver pserver /srv/git
server — Run as a plain CVS server over an already-authenticated transport.
git cvsserver server /srv/git

💡 Use cases

🧪 Examples

Enable on a repo
git config --bool gitcvs.enabled true
Pick the DBI driver and DB name
git config gitcvs.dbDriver SQLite && git config gitcvs.dbName %Ggitcvs.%m.sqlite
Run via xinetd (server line)
server = /usr/bin/git-cvsserver pserver --base-path=/srv/git --export-all
Client checkout
cvs -d :pserver:alice@127.0.0.1:/myrepo co master

🎓 Recommendations

🪤 Common pitfalls

🔗 Related modules

📝 Quiz

Hit each option, then Check answers. Score is recorded; Next is always open.