|
Lines 25-33
Link Here
|
| 25 |
<pubdate>$FreeBSD: doc/en_US.ISO8859-1/articles/cvsup-advanced/article.sgml,v 1.5 2002/05/26 21:45:41 keramida Exp $</pubdate> |
25 |
<pubdate>$FreeBSD: doc/en_US.ISO8859-1/articles/cvsup-advanced/article.sgml,v 1.5 2002/05/26 21:45:41 keramida Exp $</pubdate> |
| 26 |
|
26 |
|
| 27 |
<abstract> |
27 |
<abstract> |
| 28 |
<para>The present article assumes a basic understanding of CVSup |
28 |
<para>The present article assumes a basic understanding of <application>CVSup</application> |
| 29 |
operation. It documents several delicate issues connected with |
29 |
operation. It documents several delicate issues connected with |
| 30 |
source synchronization via CVSup, viz. effective solutions to |
30 |
source synchronization via <application>CVSup</application>, viz. effective solutions to |
| 31 |
the problem of stale files as well as special source updating |
31 |
the problem of stale files as well as special source updating |
| 32 |
cases; which issues are likely to cause apparently inexplicable |
32 |
cases; which issues are likely to cause apparently inexplicable |
| 33 |
troubles.</para> |
33 |
troubles.</para> |
|
Lines 38-44
Link Here
|
| 38 |
<title>Preface</title> |
38 |
<title>Preface</title> |
| 39 |
|
39 |
|
| 40 |
<para>This document is the fruit of the author's attempts to |
40 |
<para>This document is the fruit of the author's attempts to |
| 41 |
fully understand the niceties of cvsup & source updating. :-) |
41 |
fully understand the niceties of <command>cvsup</command> & source updating. :-) |
| 42 |
While the author has made every effort to make these pages |
42 |
While the author has made every effort to make these pages |
| 43 |
as informative and correct as possible, he is only human and |
43 |
as informative and correct as possible, he is only human and |
| 44 |
may have made all sorts of typos, mistakes, etc. He will be |
44 |
may have made all sorts of typos, mistakes, etc. He will be |
|
Lines 66-77
Link Here
|
| 66 |
your base is <filename>/usr</filename>.</para> |
66 |
your base is <filename>/usr</filename>.</para> |
| 67 |
|
67 |
|
| 68 |
<para>A checkouts file contains information on the current status |
68 |
<para>A checkouts file contains information on the current status |
| 69 |
of your sources -- in a way, a sort of "photograph". This |
69 |
of your sources -- in a way, a sort of <quote>photograph</quote>. This |
| 70 |
significant information enables cvsup to retrieve updates most |
70 |
significant information enables <command>cvsup</command> to retrieve updates most |
| 71 |
effectively. Further, and maybe more important, it enables cvsup |
71 |
effectively. Further, and maybe more important, it enables <command>cvsup</command> |
| 72 |
to correctly manage your sources by locally deleting any files |
72 |
to correctly manage your sources by locally deleting any files |
| 73 |
no longer present in the repository, thus leaving no stale files |
73 |
no longer present in the repository, thus leaving no stale files |
| 74 |
on your system. In fact, without a checkouts file, cvsup would |
74 |
on your system. In fact, without a checkouts file, <command>cvsup</command> would |
| 75 |
NOT know which files your collection was composed of (cf |
75 |
NOT know which files your collection was composed of (cf |
| 76 |
&man.cvsup.1; and the fallback method for details); as a result, |
76 |
&man.cvsup.1; and the fallback method for details); as a result, |
| 77 |
it could NOT delete on your system those files no longer present |
77 |
it could NOT delete on your system those files no longer present |
|
Lines 82-96
Link Here
|
| 82 |
have got(ten) your installation CDs.</para> |
82 |
have got(ten) your installation CDs.</para> |
| 83 |
|
83 |
|
| 84 |
<para>It is therefore recommended that you adopt the two-step procedure |
84 |
<para>It is therefore recommended that you adopt the two-step procedure |
| 85 |
outlined in the Cvsup FAQ (cf Q12, Q13); in subsequent sections, you |
85 |
outlined in the <application>CVSup</application> FAQ (cf Q12, Q13); in subsequent sections, you |
| 86 |
will be given interesting and instructive concrete examples.</para> |
86 |
will be given interesting and instructive concrete examples.</para> |
| 87 |
</sect1> |
87 |
</sect1> |
| 88 |
|
88 |
|
| 89 |
<sect1 id="script"> |
89 |
<sect1 id="script"> |
| 90 |
<title>A useful python script: cvsupchk</title> |
90 |
<title>A useful python script: <command>cvsupchk</command></title> |
| 91 |
|
91 |
|
| 92 |
<para>Alternatively, in order to examine your sources for |
92 |
<para>Alternatively, in order to examine your sources for |
| 93 |
inconsistencies, you may wish to utilize the cvsupchk python |
93 |
inconsistencies, you may wish to utilize the <command>cvsupchk</command> python |
| 94 |
script; which script is currently found in |
94 |
script; which script is currently found in |
| 95 |
<filename>/usr/ports/net/cvsup/work/cvsup-16.1/contrib/cvsupchk</filename>, |
95 |
<filename>/usr/ports/net/cvsup/work/cvsup-16.1/contrib/cvsupchk</filename>, |
| 96 |
together with a nice <filename>README</filename>. Prerequisites:</para> |
96 |
together with a nice <filename>README</filename>. Prerequisites:</para> |
|
Lines 121-127
Link Here
|
| 121 |
|
121 |
|
| 122 |
<screen>&prompt.user; <filename>/path/to/</filename><userinput>cvsupchk -d /usr -c /usr/sup/src-all/checkouts.cvs:RELENG_4 | more</userinput></screen> |
122 |
<screen>&prompt.user; <filename>/path/to/</filename><userinput>cvsupchk -d /usr -c /usr/sup/src-all/checkouts.cvs:RELENG_4 | more</userinput></screen> |
| 123 |
|
123 |
|
| 124 |
<para>In each case, cvsupchk will inspect your sources for |
124 |
<para>In each case, <command>cvsupchk</command> will inspect your sources for |
| 125 |
inconsistencies by utilizing the information contained in the |
125 |
inconsistencies by utilizing the information contained in the |
| 126 |
related checkouts file. Such anomalies as deleted files being |
126 |
related checkouts file. Such anomalies as deleted files being |
| 127 |
present (aka stale files), missing checked-out files, extra RCS |
127 |
present (aka stale files), missing checked-out files, extra RCS |
|
Lines 138-154
Link Here
|
| 138 |
|
138 |
|
| 139 |
<sect2> |
139 |
<sect2> |
| 140 |
<title>How to safely change tags when updating |
140 |
<title>How to safely change tags when updating |
| 141 |
<literal>src-all.</literal></title> |
141 |
<literal>src-all</literal></title> |
| 142 |
|
142 |
|
| 143 |
<para>If you specify eg tag=A in your supfile, cvsup will create |
143 |
<para>If you specify eg <literal>tag=A</literal> in your <filename>supfile</filename>, <command>cvsup</command> will create |
| 144 |
a checkouts file called <filename>checkouts.cvs:A</filename>: |
144 |
a checkouts file called <filename>checkouts.cvs:A</filename>: |
| 145 |
for instance, if tag=RELENG_4, a checkouts file called |
145 |
for instance, if <literal>tag=RELENG_4</literal>, a checkouts file called |
| 146 |
<filename>checkouts.cvs:RELENG_4</filename> is generated. |
146 |
<filename>checkouts.cvs:RELENG_4</filename> is generated. |
| 147 |
This file will be used to retrieve and/or store information |
147 |
This file will be used to retrieve and/or store information |
| 148 |
identifying your 4-STABLE sources.</para> |
148 |
identifying your 4-STABLE sources.</para> |
| 149 |
|
149 |
|
| 150 |
<para>When tracking <literal>src-all</literal>, if you wish to |
150 |
<para>When tracking <literal>src-all</literal>, if you wish to |
| 151 |
pass from tag=A to tag=B (A less/greater than B not making |
151 |
pass from <literal>tag=A</literal> to <literal>tag=B</literal> (A less/greater than B not making |
| 152 |
any difference) and if your checkouts file is |
152 |
any difference) and if your checkouts file is |
| 153 |
<filename>checkouts.cvs:A</filename>, the following actions |
153 |
<filename>checkouts.cvs:A</filename>, the following actions |
| 154 |
should be performed:</para> |
154 |
should be performed:</para> |
|
Lines 162-178
Link Here
|
| 162 |
</listitem> |
162 |
</listitem> |
| 163 |
|
163 |
|
| 164 |
<listitem> |
164 |
<listitem> |
| 165 |
<para>write a supfile whose collection line reads:</para> |
165 |
<para>write a <filename>supfile</filename> whose collection line reads:</para> |
| 166 |
<programlisting>src-all tag=B</programlisting> |
166 |
<programlisting>src-all tag=B</programlisting> |
| 167 |
</listitem> |
167 |
</listitem> |
| 168 |
|
168 |
|
| 169 |
<listitem> |
169 |
<listitem> |
| 170 |
<para>cvsup your sources using the new supfile.</para> |
170 |
<para>cvsup your sources using the new <filename>supfile</filename>.</para> |
| 171 |
</listitem> |
171 |
</listitem> |
| 172 |
</orderedlist> |
172 |
</orderedlist> |
| 173 |
|
173 |
|
| 174 |
<para>Cvsup will look for <filename>checkouts.cvs:B</filename> |
174 |
<para>The utility <command>cvsup</command> will look for <filename>checkouts.cvs:B</filename> |
| 175 |
-- in that the target is B; that is, cvsup will make use of |
175 |
-- in that the target is B; that is, <command>cvsup</command> will make use of |
| 176 |
the information contained therein to correctly manage your |
176 |
the information contained therein to correctly manage your |
| 177 |
sources.</para> |
177 |
sources.</para> |
| 178 |
|
178 |
|
|
Lines 185-199
Link Here
|
| 185 |
</listitem> |
185 |
</listitem> |
| 186 |
|
186 |
|
| 187 |
<listitem> |
187 |
<listitem> |
| 188 |
<para>less load is placed on the server, in that cvsup |
188 |
<para>less load is placed on the server, in that <command>cvsup</command> |
| 189 |
operates in the most efficient way.</para> |
189 |
operates in the most efficient way.</para> |
| 190 |
</listitem> |
190 |
</listitem> |
| 191 |
</itemizedlist> |
191 |
</itemizedlist> |
| 192 |
|
192 |
|
| 193 |
|
193 |
|
| 194 |
<para>For example, A=RELENG_4, B=. The period in "B=." means |
194 |
<para>For example, <literal>A=RELENG_4</literal>, <literal>B=.</literal>. The period in <literal>B=.</literal> means |
| 195 |
-CURRENT. This is a rather typical update, from 4-STABLE |
195 |
-CURRENT. This is a rather typical update, from 4-STABLE |
| 196 |
to -CURRENT. While it is straightforward to "downgrade" your |
196 |
to -CURRENT. While it is straightforward to <quote>downgrade</quote> your |
| 197 |
sources (eg from -CURRENT to -STABLE), downgrading a system |
197 |
sources (eg from -CURRENT to -STABLE), downgrading a system |
| 198 |
is quite another matter. You are STRONGLY advised not to |
198 |
is quite another matter. You are STRONGLY advised not to |
| 199 |
attempt such an operation, unless you know exactly what you |
199 |
attempt such an operation, unless you know exactly what you |
|
Lines 203-226
Link Here
|
| 203 |
<sect2> |
203 |
<sect2> |
| 204 |
<title>Updating to the same tag as of a different date</title> |
204 |
<title>Updating to the same tag as of a different date</title> |
| 205 |
|
205 |
|
| 206 |
<para>If you wish to switch from "tag=A" to "tag=A" as of a |
206 |
<para>If you wish to switch from <literal>tag=A</literal> to <literal>tag=A</literal> as of a |
| 207 |
different GMT date (say, "date=D"), you will execute the |
207 |
different GMT date (say, <literal>date=D</literal>), you will execute the |
| 208 |
following:</para> |
208 |
following:</para> |
| 209 |
|
209 |
|
| 210 |
<orderedlist> |
210 |
<orderedlist> |
| 211 |
<listitem> |
211 |
<listitem> |
| 212 |
<para>write a supfile whose collection line reads:</para> |
212 |
<para>write a <filename>supfile</filename> whose collection line reads:</para> |
| 213 |
<programlisting>src-all tag=A date=D</programlisting> |
213 |
<programlisting>src-all tag=A date=D</programlisting> |
| 214 |
</listitem> |
214 |
</listitem> |
| 215 |
|
215 |
|
| 216 |
<listitem> |
216 |
<listitem> |
| 217 |
<para>update your sources using the new supfile</para> |
217 |
<para>update your sources using the new <filename>supfile</filename></para> |
| 218 |
</listitem> |
218 |
</listitem> |
| 219 |
</orderedlist> |
219 |
</orderedlist> |
| 220 |
|
220 |
|
| 221 |
<para>Whether the new date precedes that of the last sync |
221 |
<para>Whether the new date precedes that of the last sync |
| 222 |
operation with tag=A or not, it is immaterial. For example, |
222 |
operation with <literal>tag=A</literal> or not, it is immaterial. For example, |
| 223 |
in order to specify the date "August 27, 2000, 10:00:00 GMT" |
223 |
in order to specify the date <quote>August 27, 2000, 10:00:00 GMT</quote> |
| 224 |
you write the line:</para> |
224 |
you write the line:</para> |
| 225 |
|
225 |
|
| 226 |
|
226 |
|
|
Lines 237-255
Link Here
|
| 237 |
is called <filename>checkouts.cvs:A</filename> (eg |
237 |
is called <filename>checkouts.cvs:A</filename> (eg |
| 238 |
<filename>checkouts.cvs:RELENG_4</filename>). As a result, |
238 |
<filename>checkouts.cvs:RELENG_4</filename>). As a result, |
| 239 |
no particular action is needed in order to revert to the |
239 |
no particular action is needed in order to revert to the |
| 240 |
previous state: you have to modify the date in the supfile, |
240 |
previous state: you have to modify the date in the <filename>supfile</filename>, |
| 241 |
and csvup again.</para> |
241 |
and run <command>csvup</command> again.</para> |
| 242 |
</sect2> |
242 |
</sect2> |
| 243 |
|
243 |
|
| 244 |
|
244 |
|
| 245 |
<sect2> |
245 |
<sect2> |
| 246 |
<title>Updating your ports collection for the first time</title> |
246 |
<title>Updating your ports collection for the first time</title> |
| 247 |
|
247 |
|
| 248 |
<para>Since ports are tagged "." (ie -CURRENT), you can |
248 |
<para>Since ports are tagged <quote>.</quote> (ie -CURRENT), you can |
| 249 |
correctly "sync" them for the first time by adding the date |
249 |
correctly <quote>sync</quote> them for the first time by adding the date |
| 250 |
keyword (cf &man.cvsup.1; for the exact format): you should |
250 |
keyword (cf &man.cvsup.1; for the exact format): you should |
| 251 |
specify a date as close as possible to that of "shipping" of |
251 |
specify a date as close as possible to that of <quote>shipping</quote> of |
| 252 |
your ports tree. After cvsup has correctly created the ports |
252 |
your ports tree. After <command>cvsup</command> has correctly created the ports |
| 253 |
checkouts file, which is precisely the goal of this first |
253 |
checkouts file, which is precisely the goal of this first |
| 254 |
special sync operation, the date field must be removed; |
254 |
special sync operation, the date field must be removed; |
| 255 |
all subsequent updates will be carried out smoothly.</para> |
255 |
all subsequent updates will be carried out smoothly.</para> |