1<div id="checkout"></div>
2<div class="header">
3<p>
4Next: [[cvs: commit--Check files into the repository#commit&mdash;Check files into the repository|commit]], Previous: [[cvs: admin--Administration#admin&mdash;Administration|admin]], Up: [[cvs: Guide to CVS commands#Guide to CVS commands|CVS commands]] &nbsp; |[[cvs: Index#SEC_Contents|Contents]]||[[cvs: Index#Index|Index]]|</p>
5</div>
6
7----
8
9<div id="checkout_002d_002d_002dCheck-out-sources-for-editing"></div>
10=== checkout&mdash;Check out sources for editing ===
11<div id="index-checkout-_0028subcommand_0029"></div>
12<div id="index-co-_0028subcommand_0029"></div>
13
14
15* Synopsis: checkout <nowiki>[</nowiki>options<nowiki>]</nowiki> modules&hellip;
16
17* Requires: repository.
18
19* Changes: working directory.
20
21* Synonyms: co, get
22
23Create or update a working directory containing copies of the
24source files specified by <var>modules</var>.  You must execute
25<code>checkout</code> before using most of the other <small>CVS</small>
26commands, since most of them operate on your working
27directory.
28
29The <var>modules</var> are either
30symbolic names for some
31collection of source directories and files, or paths to
32directories or files in the repository.  The symbolic
33names are defined in the &lsquo;<code>modules</code>&rsquo; file.
34See [[cvs: The modules file#The modules file|modules]].
35
36Depending on the modules you specify, <code>checkout</code> may
37recursively create directories and populate them with
38the appropriate source files.  You can then edit these
39source files at any time (regardless of whether other
40software developers are editing their own copies of the
41sources); update them to include new changes applied by
42others to the source repository; or commit your work as
43a permanent change to the source repository.
44
45Note that <code>checkout</code> is used to create
46directories.  The top-level directory created is always
47added to the directory where <code>checkout</code> is
48invoked, and usually has the same name as the specified
49module.  In the case of a module alias, the created
50sub-directory may have a different name, but you can be
51sure that it will be a sub-directory, and that
52<code>checkout</code> will show the relative path leading to
53each file as it is extracted into your private work
54area (unless you specify the &lsquo;<code>-Q</code>&rsquo; global option).
55
56The files created by <code>checkout</code> are created
57read-write, unless the &lsquo;<code>-r</code>&rsquo; option to <small>CVS</small>
58(see [[cvs: Global options#Global options|Global options]]) is specified, the
59<code>CVSREAD</code> environment variable is specified
60(see [[cvs: All environment variables which affect CVS#All environment variables which affect CVS|Environment variables]]), or a watch is in
61effect for that file (see [[cvs: Mechanisms to track who is editing files#Mechanisms to track who is editing files|Watches]]).
62
63Note that running <code>checkout</code> on a directory that was already
64built by a prior <code>checkout</code> is also permitted.
65This is similar to specifying the &lsquo;<code>-d</code>&rsquo; option
66to the <code>update</code> command in the sense that new
67directories that have been created in the repository
68will appear in your work area.
69However, <code>checkout</code> takes a module name whereas
70<code>update</code> takes a directory name.  Also
71to use <code>checkout</code> this way it must be run from the
72top level directory (where you originally ran
73<code>checkout</code> from), so before you run
74<code>checkout</code> to update an existing directory, don&rsquo;t
75forget to change your directory to the top level
76directory.
77
78For the output produced by the <code>checkout</code> command
79see [[cvs: update output#update output|update output]].
80
81 [[cvs: checkout options#checkout options|&bull; checkout options]]::            checkout options
82 [[cvs: checkout examples#checkout examples|&bull; checkout examples]]::           checkout examples
83
84
85----
86
87<div class="header">
88<p>
89Next: [[cvs: commit--Check files into the repository#commit&mdash;Check files into the repository|commit]], Previous: [[cvs: admin--Administration#admin&mdash;Administration|admin]], Up: [[cvs: Guide to CVS commands#Guide to CVS commands|CVS commands]] &nbsp; |[[cvs: Index#SEC_Contents|Contents]]||[[cvs: Index#Index|Index]]|</p>
90</div>
91This document was generated on <i>a sunny day</i> using [http://www.nongnu.org/texi2html/ <i>texi2html</i>].
92