debcheckout
checkout the development repository of a Debian package
- Provided by: devscripts (Version: 2.25.19ubuntu2)
- Report a bug
checkout the development repository of a Debian package
debcheckout retrieves the information about the Version Control System used to maintain a given Debian package (the PACKAGE argument), and then checks out the latest (potentially unreleased) version of the package from its repository. By default the repository is checked out to the PACKAGE directory; this can be overridden by providing the DESTDIR argument.
The information about where the repository is available is expected to be found in Vcs-* fields available in the source package record. For example, the vim package exposes such information with a field like Vcs-Hg: http://hg.debian.org/hg/pkg-vim/vim, you can see it by grepping through apt-cache showsrc vim.
If more than one source package record containing Vcs-* fields is available, debcheckout will select the record with the highest version number. Alternatively, a particular version may be selected from those available by specifying the package name as PACKAGE=VERSION.
If you already know the URL of a given repository you can invoke debcheckout directly on it, but you will probably need to pass the appropriate -t flag. That is, some heuristics are in use to guess the repository type from the URL; if they fail, you might want to override the guessed type using -t.
The currently supported version control systems are: Arch (arch), Bazaar (bzr), CVS (cvs), Darcs (darcs), Git (git), Mercurial (hg) and Subversion (svn).
GENERAL OPTIONS
There are built-in rules for salsa.debian.org and github.com. Other hosts can be configured using DEBCHECKOUT_AUTH_URLS.
Also see -p. This option and -p are mutually exclusive.
Also see -d. This option and -d are mutually exclusive.
VCS-SPECIFIC OPTIONS
GIT-SPECIFIC OPTIONS
As a shorthand, the string "*" can be given to require tracking of all remote branches.
The two configuration files /etc/devscripts.conf and ~/.devscripts are sourced by a shell in that order to set configuration variables. Command line options can be used to override configuration file settings. Environment variable settings are ignored for this purpose. The currently recognised variables are:
References to matching substrings in the replacement texts are allowed as usual in Perl by the means of $1, $2, ... and so on.
This setting is used to configure the "authenticated mode" location for repositories. The Debian repositories on salsa.debian.org are implicitly defined, as is github.com.
Here is a sample snippet suitable for the configuration files:
DEBCHECKOUT_AUTH_URLS='
^\w+://(svn\.example\.com)/(.*) svn+ssh://$1/srv/svn/$2
^\w+://(git\.example\.com)/(.*) git+ssh://$1/home/git/$2
'
Note that whitespace is not allowed in either regexps or replacement texts. Also, given that configuration files are sourced by a shell, you probably want to use single quotes around the value of this variable.
apt-cache(8), Section 6.2.5 of the Debian Developer's Reference (for more information about Vcs-* fields): https://www.debian.org/doc/developers-reference/best-pkging-practices.html#bpp-vcs.
debcheckout and this manpage have been written by Stefano Zacchiroli <zack@debian.org>.