Mercurial > hgbook
comparison ja/branch.tex @ 835:8a3041e6f3cb
reflect comments by Hiroshi Someya.
author | Yoshiki Yazawa <yaz@honeyplanet.jp> |
---|---|
date | Sat, 11 Jul 2009 19:25:35 +0900 |
parents | 5276f40fca1c |
children |
comparison
equal
deleted
inserted
replaced
834:896ab6eaf1c6 | 835:8a3041e6f3cb |
---|---|
15 %substantial new features. In parallel, they may issue ``minor'' | 15 %substantial new features. In parallel, they may issue ``minor'' |
16 %releases. These are usually identical to the major releases off which | 16 %releases. These are usually identical to the major releases off which |
17 %they're based, but with a few bugs fixed. | 17 %they're based, but with a few bugs fixed. |
18 | 18 |
19 $BB?$/$N%=%U%H%&%'%"%W%m%8%'%/%H$G$O!$?75!G=$r;}$D%a%8%c!<%j%j!<%9$rDj4|E*(B | 19 $BB?$/$N%=%U%H%&%'%"%W%m%8%'%/%H$G$O!$?75!G=$r;}$D%a%8%c!<%j%j!<%9$rDj4|E*(B |
20 $B$K%j%j!<%9$9$k!%JB9T$7$FB??t$N%^%$%J!<%j%j!<%9$b9T$J$o$l$k!%$3$l$i$O%a(B | 20 $B$K%j%j!<%9$9$k!%JB9T$7$FB??t$N%^%$%J!<%j%j!<%9$b9T$o$l$k!%$3$l$i$O%a(B |
21 $B%8%c!<%j%j!<%9$N%P%0$r=$@5$7$?$b$N$G$"$k!%(B | 21 $B%8%c!<%j%j!<%9$N%P%0$r=$@5$7$?$b$N$G$"$k!%(B |
22 | 22 |
23 %In this chapter, we'll start by talking about how to keep records of | 23 %In this chapter, we'll start by talking about how to keep records of |
24 %project milestones such as releases. We'll then continue on to talk | 24 %project milestones such as releases. We'll then continue on to talk |
25 %about the flow of work between different phases of a project, and how | 25 %about the flow of work between different phases of a project, and how |
65 %\item Colon (ASCII 58, ``\texttt{:}'') | 65 %\item Colon (ASCII 58, ``\texttt{:}'') |
66 %\item Carriage return (ASCII 13, ``\Verb+\r+'') | 66 %\item Carriage return (ASCII 13, ``\Verb+\r+'') |
67 %\item Newline (ASCII 10, ``\Verb+\n+'') | 67 %\item Newline (ASCII 10, ``\Verb+\n+'') |
68 %\end{itemize} | 68 %\end{itemize} |
69 | 69 |
70 $B%?%0$O<B$N$H$3$m%j%S%8%g%s$KIU$1$i$l$?%7%s%\%j%C%/%M!<%`$KB>$J$i$J$$!%%?(B | 70 $B%?%0$O<B$N$H$3$m%j%S%8%g%s$KIU$1$i$l$?%7%s%\%kL>$KB>$J$i$J$$!%%?%0$OC1$K(B |
71 $B%0$OC1$K%f!<%6$NJX59$N$?$a$KIU$1$i$l$k!%%?%0$OFCDj$N%j%S%8%g%s$r;2>H$9$k(B | 71 $B%f!<%6$NJX59$N$?$a$KIU$1$i$l$k!%%?%0$OFCDj$N%j%S%8%g%s$r;2>H$9$k$?$a$N<j(B |
72 $B$?$a$N<j7Z$G1JB3E*$JJ}K!$G!$(BMercurial$B$O%?%0$rK]Lu$7$J$$!%%?%0$NL>A0$K$O!$(B | 72 $B7Z$G1JB3E*$JJ}K!$G!$(BMercurial$B$O%?%0$rK]Lu$7$J$$!%%?%0$NL>A0$K$O!$L@3N$K%Q!<(B |
73 $BL@3N$K%Q!<%9$9$k$?$a$N$$$/$D$+$N$b$N0J30$N@)8B$O$J$$!%%?%0%M!<%`$O0J2<$N(B | 73 $B%9$9$k$?$a$KI,MW$J$$$/$D$+$N$b$N0J30$K@)8B$O$J$$!%%?%0%M!<%`$O0J2<$NJ8;z(B |
74 $BJ8;z$r4^$`$3$H$O$G$-$J$$!%(B | 74 $B$r4^$`$3$H$O$G$-$J$$!%(B |
75 \begin{itemize} | 75 \begin{itemize} |
76 \item $B%3%m%s(B (ASCII 58, ``\texttt{:}'') | 76 \item $B%3%m%s(B (ASCII 58, ``\texttt{:}'') |
77 \item $BI|5"J8;z(B (ASCII 13, ``\Verb+\r+'') | 77 \item $BI|5"J8;z(B (ASCII 13, ``\Verb+\r+'') |
78 \item $B2~9TJ8;z(B (ASCII 10, ``\Verb+\n+'') | 78 \item $B2~9TJ8;z(B (ASCII 10, ``\Verb+\n+'') |
79 \end{itemize} | 79 \end{itemize} |
80 | 80 |
81 | 81 |
82 %You can use the \hgcmd{tags} command to display the tags present in | 82 %You can use the \hgcmd{tags} command to display the tags present in |
83 %your repository. In the output, each tagged revision is identified | 83 %your repository. In the output, each tagged revision is identified |
84 %first by its name, then by revision number, and finally by the unique | 84 %first by its name, then by revision number, and finally by the unique |
85 %hash of the revision. | 85 %hash of the revision. |
86 %\interaction{tag.tags} | 86 %\interaction{tag.tags} |
87 %Notice that \texttt{tip} is listed in the output of \hgcmd{tags}. The | 87 %Notice that \texttt{tip} is listed in the output of \hgcmd{tags}. The |
88 %\texttt{tip} tag is a special ``floating'' tag, which always | 88 %\texttt{tip} tag is a special ``floating'' tag, which always |
89 %identifies the newest revision in the repository. | 89 %identifies the newest revision in the repository. |
90 | 90 |
131 %you to find revisions. If you have lots of tags, the ease of using them | 131 %you to find revisions. If you have lots of tags, the ease of using them |
132 %to identify revisions diminishes rapidly. | 132 %to identify revisions diminishes rapidly. |
133 | 133 |
134 $B%j%]%8%H%j$NCf$G;H$($k%?%0?t!$0l$D$N%j%S%8%g%s$KIU$1$i$l$k%?%0?t$K>e8B$O(B | 134 $B%j%]%8%H%j$NCf$G;H$($k%?%0?t!$0l$D$N%j%S%8%g%s$KIU$1$i$l$k%?%0?t$K>e8B$O(B |
135 $B$J$$!%;v>p$O%W%m%8%'%/%H$K$h$C$F0[$J$k$@$m$&$,!$<BMQE*$K$O%?%0$rB?$/IU$1(B | 135 $B$J$$!%;v>p$O%W%m%8%'%/%H$K$h$C$F0[$J$k$@$m$&$,!$<BMQE*$K$O%?%0$rB?$/IU$1(B |
136 $B$9$.$k$3$H$O$"$^$jNI$$9M$($H$O8@$($J$$!%%?%0$H$O%j%S%8%g%s$r8+$D$10W$/$9(B | 136 $B$9$.$k$3$H$O$"$^$jNI$$9M$($H$O8@$($J$$!%%?%0$H$O%j%S%8%g%s$r8+$D$1$d$9$/(B |
137 $B$k$?$a$K;H$&$b$N$@$+$i$@!%%?%0$rB?$/IU$1$9$.$k$H!$%?%0$K$h$C$F%j%S%8%g%s(B | 137 $B$9$k$?$a$K;H$&$b$N$@$+$i$@!%%?%0$rB?$/IU$1$9$.$k$H!$%?%0$K$h$C$F%j%S%8%g(B |
138 $B$N6hJL$r$9$k$3$H$,$H$?$s$KFq$7$/$J$k!%(B | 138 $B%s$N6hJL$r$9$k$3$H$,$H$?$s$KFq$7$/$J$k!%(B |
139 | 139 |
140 %For example, if your project has milestones as frequent as every few | 140 %For example, if your project has milestones as frequent as every few |
141 %days, it's perfectly reasonable to tag each one of those. But if you | 141 %days, it's perfectly reasonable to tag each one of those. But if you |
142 %have a continuous build system that makes sure every revision can be | 142 %have a continuous build system that makes sure every revision can be |
143 %built cleanly, you'd be introducing a lot of noise if you were to tag | 143 %built cleanly, you'd be introducing a lot of noise if you were to tag |
279 %that revision \texttt{4237e45506ee} is really \texttt{v2.0.2}. If | 279 %that revision \texttt{4237e45506ee} is really \texttt{v2.0.2}. If |
280 %you're trying to track down a subtle bug, you might want a tag to | 280 %you're trying to track down a subtle bug, you might want a tag to |
281 %remind you of something like ``Anne saw the symptoms with this | 281 %remind you of something like ``Anne saw the symptoms with this |
282 %revision''. | 282 %revision''. |
283 | 283 |
284 Mercurial$B$N%?%0$O%j%S%8%g%s%3%s%H%m!<%k$5$l!$%W%m%8%'%/%HMzNr$KIU?o$7$F$$(B | 284 Mercurial$B$N%?%0$O%j%S%8%g%s%3%s%H%m!<%k$5$l!$%W%m%8%'%/%H$NMzNr$KIU?o$7$F(B |
285 $B$k$?$a!$F1$8%W%m%8%'%/%H$GF/$/?M$O3'%?%0$rCN$k$3$H$K$J$k!%%j%S%8%g%s$KL>(B | 285 $B$$$k$?$a!$F1$8%W%m%8%'%/%H$GF/$/?M$O3'%?%0$rCN$k$3$H$K$J$k!%%j%S%8%g%s$K(B |
286 $BA0$rIU$1$k$3$H$O!$C1$K%j%S%8%g%s(B\texttt{4237e45506ee}$B$,%P!<%8%g%s(B | 286 $BL>A0$rIU$1$k$3$H$O!$C1$K%j%S%8%g%s(B\texttt{4237e45506ee}$B$,%P!<%8%g%s(B |
287 \texttt{v2.0.2}$B$G$"$k$H5-=R$9$k0J>e$N0UL#$r;}$D!%$b$7%P%0$rDI@W$7$F$$$k$J(B | 287 \texttt{v2.0.2}$B$G$"$k$H5-=R$9$k0J>e$N0UL#$r;}$D!%$b$7%P%0$rDI@W$7$F$$$k$J(B |
288 $B$i!$(B``Anne saw the symptoms with this revision''$B!J%"%s$O$3$N%j%S%8%g%s$G(B | 288 $B$i!$(B``Anne saw the symptoms with this revision''$B!J%"%s$O$3$N%j%S%8%g%s$G(B |
289 $B>I>u$r8+$?!K$J$I$N%?%0$rIU$1$?$/$J$k$@$m$&!%(B | 289 $B>I>u$r8+$?!K$J$I$N%?%0$rIU$1$?$/$J$k$@$m$&!%(B |
290 | 290 |
291 %For cases like this, what you might want to use are \emph{local} tags. | 291 %For cases like this, what you might want to use are \emph{local} tags. |
316 | 316 |
317 %There might be a push for a new ``main'' release; a new minor bugfix | 317 %There might be a push for a new ``main'' release; a new minor bugfix |
318 %release to the last main release; and an unexpected ``hot fix'' to an | 318 %release to the last main release; and an unexpected ``hot fix'' to an |
319 %old release that is now in maintenance mode. | 319 %old release that is now in maintenance mode. |
320 | 320 |
321 $B?7$7$$(B``main''$B$r%j%j!<%9$9$k>u67$G!$:G?7$N%a%$%s%j%j!<%9$KBP$9$k?7$7$$>.(B | 321 $B?7$7$$(B``main''$B$r%j%j!<%9$9$k=`Hw$K$+$+$C$F$$$k>uBV$G!$:G?7$N%a%$%s%j%j!<(B |
322 $B5,LO$J%P%0%U%#%C%/%9%j%j!<%9$H4{$K%a%s%F%J%s%9%b!<%I$K$J$C$F$$$k8E$$%j%j!<(B | 322 $B%9$KBP$9$k?7$7$$>.5,LO$J%P%0%U%#%C%/%9%j%j!<%9$H!$4{$K%a%s%F%J%s%9%b!<%I(B |
323 $B%98~$1$NM=4|$;$L(B``hot fix'' $B$r%j%j!<%9$9$k>u67$r9M$($k!%(B | 323 $B$K$J$C$F$$$k8E$$%j%j!<%98~$1$N7W2h30$N(B``hot fix''$B$r%j%j!<%9$9$k>u67$r9M$((B |
324 $B$k!%(B | |
324 | 325 |
325 | 326 |
326 %The usual way people refer to these different concurrent directions of | 327 %The usual way people refer to these different concurrent directions of |
327 %development is as ``branches''. However, we've already seen numerous | 328 %development is as ``branches''. However, we've already seen numerous |
328 %times that Mercurial treats \emph{all of history} as a series of | 329 %times that Mercurial treats \emph{all of history} as a series of |
360 %\interaction{branch-repo.tag} | 361 %\interaction{branch-repo.tag} |
361 %You can then clone a new shared \texttt{myproject-1.0.1} repository as | 362 %You can then clone a new shared \texttt{myproject-1.0.1} repository as |
362 %of that tag. | 363 %of that tag. |
363 %\interaction{branch-repo.clone} | 364 %\interaction{branch-repo.clone} |
364 | 365 |
365 Mercurial$B$G(B``bit picture''$B$r3VN%$9$k:G$b4JC1$JJ}K!$O!$@lMQ$N%j%]%8%H%j$r(B | 366 Mercurial$B$G(B``big picture''$B$r3VN%$9$k:G$b4JC1$JJ}K!$O!$@lMQ$N%j%]%8%H%j$r(B |
366 $BMQ0U$9$k$3$H$G$"$k!%$b$70l$D$N6&M-%j%]%8%H%j$r;}$C$F$$$k>l9g!$$3$l$r(B | 367 $BMQ0U$9$k$3$H$G$"$k!%$b$70l$D$N6&M-%j%]%8%H%j$r;}$C$F$$$k>l9g!$$3$l$r(B |
367 \texttt{myproject}$B$H8F$V$3$H$K$7$k!%$3$l$,(B``1.0''$B%^%$%k%9%H!<%s$KE~C#$7$?(B | 368 \texttt{myproject}$B$H8F$V$3$H$K$7$k!%$3$l$,(B``1.0''$B%^%$%k%9%H!<%s$KE~C#$7$?(B |
368 $B$i!$(B1.0$B$K(B1.0$B%j%j!<%9$H%?%0$rIU$1!$>-Mh$N%a%s%F%J%s%9%j%j!<%9$KHw$($k$3$H(B | 369 $B$i!$(B1.0$B$K(B1.0$B%j%j!<%9$H%?%0$rIU$1!$>-Mh$N%a%s%F%J%s%9%j%j!<%9$KHw$($k$3$H(B |
369 $B$,$G$-$k!%(B | 370 $B$,$G$-$k!%(B |
370 \interaction{branch-repo.tag} | 371 \interaction{branch-repo.tag} |
429 %branch/repository. | 430 %branch/repository. |
430 | 431 |
431 $BB?$/$N>l9g!$%V%i%s%AKh$KJ#?t$N%j%]%8%H%j$rMQ0U$73VN%$9$k$N$O@5$7$$%"%W%m!<(B | 432 $BB?$/$N>l9g!$%V%i%s%AKh$KJ#?t$N%j%]%8%H%j$rMQ0U$73VN%$9$k$N$O@5$7$$%"%W%m!<(B |
432 $B%A$G$"$k!%$3$l$OC1=c$J$?$aGD0.$,MF0W$G$"$j!$<:GT$rHH$92DG=@-$,Dc$$!%:n6H(B | 433 $B%A$G$"$k!%$3$l$OC1=c$J$?$aGD0.$,MF0W$G$"$j!$<:GT$rHH$92DG=@-$,Dc$$!%:n6H(B |
433 $B$7$F$$$k%V%i%s%A$H%G%#%l%/%H%j$N4V$K$O(B1$BBP(B1$B$N4X78$,$"$k!%(BMercurial$B$r9MN8$7(B | 434 $B$7$F$$$k%V%i%s%A$H%G%#%l%/%H%j$N4V$K$O(B1$BBP(B1$B$N4X78$,$"$k!%(BMercurial$B$r9MN8$7(B |
434 $B$J$$DL>o$N%D!<%k$r%V%i%s%A!?%j%]%8%H%jFb$N%U%!%$%k$KBg$7$F;H$&$3$H$b2DG=(B | 435 $B$J$$DL>o$N%D!<%k$r%V%i%s%A!?%j%]%8%H%jFb$N%U%!%$%k$KBP$7$F;H$&$3$H$b2DG=(B |
435 $B$G$"$k!%(B | 436 $B$G$"$k!%(B |
436 | 437 |
437 %If you're more in the ``power user'' category (\emph{and} your | 438 %If you're more in the ``power user'' category (\emph{and} your |
438 %collaborators are too), there is an alternative way of handling | 439 %collaborators are too), there is an alternative way of handling |
439 %branches that you can consider. I've already mentioned the | 440 %branches that you can consider. I've already mentioned the |
512 | 513 |
513 $B%V%i%s%A$r:n$C$?8e$G(B\hgcmd{branch}$B%3%^%s%I$,$I$N$h$&$J8z2L$r;}$C$F$$$k$N(B | 514 $B%V%i%s%A$r:n$C$?8e$G(B\hgcmd{branch}$B%3%^%s%I$,$I$N$h$&$J8z2L$r;}$C$F$$$k$N(B |
514 $B$+J,$+$i$J$$$+$b$7$l$J$$!%(B\hgcmd{status}$B%3%^%s%I$H(B\hgcmd{tip}$B%3%^%s%I$O(B | 515 $B$+J,$+$i$J$$$+$b$7$l$J$$!%(B\hgcmd{status}$B%3%^%s%I$H(B\hgcmd{tip}$B%3%^%s%I$O(B |
515 $B$=$l$>$l2?$rI=<($9$k$@$m$&$+!)(B | 516 $B$=$l$>$l2?$rI=<($9$k$@$m$&$+!)(B |
516 \interaction{branch-named.status} | 517 \interaction{branch-named.status} |
517 $B%o!<%-%s%0%G%#%l%/%H%jFb$G$O2?$bJQ2=$O5/$-$:!$2?$N%R%9%H%j$b@8@.$5$l$F$$(B | 518 $B%o!<%-%s%0%G%#%l%/%H%jFb$G$O2?$bJQ2=$O5/$-$:!$2?$NMzNr$b@8@.$5$l$F$$$J(B |
518 $B$J$$!%$3$l$+$iJ,$+$k$h$&$K!$(B\hgcmd{branch}$B%3%^%s%I$r<B9T$7$F$b!$1JB3E*$J(B | 519 $B$$!%$3$l$+$iJ,$+$k$h$&$K!$(B\hgcmd{branch}$B%3%^%s%I$r<B9T$7$F$b!$1JB3E*$J8z(B |
519 $B8z2L$O2?$b5/$-$J$$!%$3$N%3%^%s%I$O(B\emph{$B<!$N(B}$B%A%'%s%8%;%C%H$N%3%_%C%H$,(B | 520 $B2L$O2?$b5/$-$J$$!%$3$N%3%^%s%I$O(B\emph{$B<!$N(B}$B%A%'%s%8%;%C%H$N%3%_%C%H$,$I$N(B |
520 $B$I$N%V%i%s%A$KBP$7$F9T$o$l$k$+$r(BMercurial$B%3%^%s%I$K<($9$N$K;H$o$l$k!%(B | 521 $B%V%i%s%A$KBP$7$F9T$o$l$k$+$r(BMercurial$B%3%^%s%I$K<($9$N$K;H$o$l$k!%(B |
521 | 522 |
522 %When you commit a change, Mercurial records the name of the branch on | 523 %When you commit a change, Mercurial records the name of the branch on |
523 %which you committed. Once you've switched from the \texttt{default} | 524 %which you committed. Once you've switched from the \texttt{default} |
524 %branch to another and committed, you'll see the name of the new branch | 525 %branch to another and committed, you'll see the name of the new branch |
525 %show up in the output of \hgcmd{log}, \hgcmd{tip}, and other commands | 526 %show up in the output of \hgcmd{log}, \hgcmd{tip}, and other commands |
538 $B$$>l9g$O$3$N=PNO$rL\$K$9$k$3$H$O$J$$!%(B | 539 $B$$>l9g$O$3$N=PNO$rL\$K$9$k$3$H$O$J$$!%(B |
539 | 540 |
540 %Once you've named a branch and committed a change with that name, | 541 %Once you've named a branch and committed a change with that name, |
541 %every subsequent commit that descends from that change will inherit | 542 %every subsequent commit that descends from that change will inherit |
542 %the same branch name. You can change the name of a branch at any | 543 %the same branch name. You can change the name of a branch at any |
543 %time, using the \hgcmd{branch} command. | 544 %time, using the \hgcmd{branch} command. |
544 %\interaction{branch-named.rebranch} | 545 %\interaction{branch-named.rebranch} |
545 %In practice, this is something you won't do very often, as branch | 546 %In practice, this is something you won't do very often, as branch |
546 %names tend to have fairly long lifetimes. (This isn't a rule, just an | 547 %names tend to have fairly long lifetimes. (This isn't a rule, just an |
547 %observation.) | 548 %observation.) |
548 | 549 |
549 $B%V%i%s%A$KL>A0$rIU$1!$$=$NL>A0$r;H$C$FJQ99$N%3%_%C%H$r9T$&$H!$0J8e$KB3$/(B | 550 $B%V%i%s%A$KL>A0$rIU$1!$$=$NL>A0$r;H$C$FJQ99$N%3%_%C%H$r9T$&$H!$0J8e$KB3$/(B |
550 $BA4$F$N%3%_%C%H$OF1$8L>A0$r;}$D!%L>A0$NJQ99$O(B\hgcmd{branch}$B%3%^%s%I$r;H$&$3(B | 551 $BA4$F$N%3%_%C%H$OF1$8L>A0$r;}$D!%L>A0$NJQ99$O(B\hgcmd{branch}$B%3%^%s%I$r;H$&$3(B |
551 $B$H$G$O$$$D$G$b2DG=$@!%(B | 552 $B$H$G$$$D$G$b2DG=$@!%(B |
552 \interaction{branch-named.rebranch} | 553 \interaction{branch-named.rebranch} |
553 $B<BMQ$K$*$$$F$O!$%V%i%s%AL>$O$+$J$jD9$$4|4V;H$o$l$k798~$,$"$j!$JQ99$OIQHK(B | 554 $B<BMQ$K$*$$$F$O!$%V%i%s%AL>$O$+$J$jD9$$4|4V;H$o$l$k798~$,$"$j!$JQ99$OIQHK(B |
554 $B$K$O9T$o$l$J$$!%!J$3$l$OK!B'$H8@$($k$h$&$J$b$N$G$O$J$/!$C1$J$k4QB,7k2L$G(B | 555 $B$K$O9T$o$l$J$$!%!J$3$l$OK!B'$H8@$($k$h$&$J$b$N$G$O$J$/!$C1$J$k4QB,7k2L$G(B |
555 $B$"$k!%!K(B | 556 $B$"$k!%!K(B |
556 | 557 |
578 %branches are in our repository. | 579 %branches are in our repository. |
579 %\interaction{branch-named.parents} | 580 %\interaction{branch-named.parents} |
580 %We're on the \texttt{bar} branch, but there also exists an older | 581 %We're on the \texttt{bar} branch, but there also exists an older |
581 %\texttt{foo} branch. | 582 %\texttt{foo} branch. |
582 | 583 |
583 $B$3$N$U$k$^$$$O$d$d4q0[$+$b$7$l$J$$!%<B:]$NF0:n$r8+$F$_$k$3$H$K$9$k!%$^$:(B | 584 $B$3$N?6Iq$$$O$d$d4q0[$+$b$7$l$J$$!%<B:]$NF0:n$r8+$F$_$k$3$H$K$9$k!%$^$:2f!9(B |
584 $B2f!9$,$I$N%V%i%s%A$K$$$k$+$rD4$Y!$%j%]%8%H%j$K$I$s$J%V%i%s%A$,$"$k$+8+$F(B | 585 $B$,$I$N%V%i%s%A$K$$$k$+$rD4$Y!$%j%]%8%H%j$K$I$s$J%V%i%s%A$,$"$k$+8+$F$_$h(B |
585 $B$_$h$&!%(B | 586 $B$&!%(B |
586 \interaction{branch-named.parents} | 587 \interaction{branch-named.parents} |
587 $B:#$$$k$N$O(B\texttt{bar}$B%V%i%s%A$G!$(B\texttt{foo}$B%V%i%s%A$bB8:_$9$k!%(B | 588 $B:#$$$k$N$O(B\texttt{bar}$B%V%i%s%A$G!$(B\texttt{foo}$B%V%i%s%A$bB8:_$9$k!%(B |
588 | 589 |
589 %We can \hgcmd{update} back and forth between the tips of the | 590 %We can \hgcmd{update} back and forth between the tips of the |
590 %\texttt{foo} and \texttt{bar} branches without needing to use the | 591 %\texttt{foo} and \texttt{bar} branches without needing to use the |
637 %branch name will still be \texttt{foo} after you merge. | 638 %branch name will still be \texttt{foo} after you merge. |
638 | 639 |
639 $B$3$l$O%^!<%8$N:]$K(BMercurial$B$,%V%i%s%AL>$r$I$N$h$&$KA*$V$+$K1F6A$rM?$($k!%(B | 640 $B$3$l$O%^!<%8$N:]$K(BMercurial$B$,%V%i%s%AL>$r$I$N$h$&$KA*$V$+$K1F6A$rM?$($k!%(B |
640 $B%^!<%88e!"%^!<%8$N7k2L$r%3%_%C%H$9$k:]$K(BMercurial$B$O(B1$BHVL\$N?F$N%V%i%s%AL>(B | 641 $B%^!<%88e!"%^!<%8$N7k2L$r%3%_%C%H$9$k:]$K(BMercurial$B$O(B1$BHVL\$N?F$N%V%i%s%AL>(B |
641 $B$rMQ$$$k!%(B1$BHVL\$N?F$N%V%i%s%AL>$,(B\texttt{foo}$B$G!$(B\texttt{bar}$B$H%^!<%8$r(B | 642 $B$rMQ$$$k!%(B1$BHVL\$N?F$N%V%i%s%AL>$,(B\texttt{foo}$B$G!$(B\texttt{bar}$B$H%^!<%8$r(B |
642 $B9T$J$C$?$H$9$k$H!$%^!<%88e$N%V%i%s%AL>$O(B\texttt{foo}$B$H$J$k!%(B | 643 $B9T$C$?$H$9$k$H!$%^!<%88e$N%V%i%s%AL>$O(B\texttt{foo}$B$H$J$k!%(B |
643 | 644 |
644 %It's not unusual for a repository to contain multiple heads, each with | 645 %It's not unusual for a repository to contain multiple heads, each with |
645 %the same branch name. Let's say I'm working on the \texttt{foo} | 646 %the same branch name. Let's say I'm working on the \texttt{foo} |
646 %branch, and so are you. We commit different changes; I pull your | 647 %branch, and so are you. We commit different changes; I pull your |
647 %changes; I now have two heads, each claiming to be on the \texttt{foo} | 648 %changes; I now have two heads, each claiming to be on the \texttt{foo} |
648 %branch. The result of a merge will be a single head on the | 649 %branch. The result of a merge will be a single head on the |
649 %\texttt{foo} branch, as you might hope. | 650 %\texttt{foo} branch, as you might hope. |
650 | 651 |
651 1$B$D$N%j%]%8%H%j$,F1$8%V%i%s%AL>$r;}$D$$$/$D$b$N(Bhead$B$r;}$C$F$$$k$3$H$ODA$7(B | 652 1$B$D$N%j%]%8%H%j$,F1$8%V%i%s%AL>$r;}$D$$$/$D$b$N(Bhead$B$r;}$C$F$$$k$3$H$ODA$7(B |
652 $B$$$3$H$G$O$J$$!%:#!$;d$H$"$J$?$,F1$8(B\texttt{foo}$B%V%i%s%A$G:n6H$r$7$F$*$j!$(B | 653 $B$$$3$H$G$O$J$$!%:#!$;d$H$"$J$?$,F1$8(B\texttt{foo}$B%V%i%s%A$G:n6H$r$7$F$*$j!$(B |
653 $B$=$l$>$l0[$J$C$?JQ99$r%3%_%C%H$9$k$H$7$h$&!%$"$J$?$N9T$J$C$?JQ99$r;d$,(B | 654 $B$=$l$>$l0[$J$C$?JQ99$r%3%_%C%H$9$k$H$7$h$&!%$"$J$?$N9T$C$?JQ99$r;d$,(B |
654 pull$B$9$k$H!$;d$O(B\texttt{foo}$B%V%i%s%A$K(B2$B$D$N(Bhead$B$r;}$D$3$H$K$J$k!%%^!<%8(B | 655 pull$B$9$k$H!$;d$O(B\texttt{foo}$B%V%i%s%A$K(B2$B$D$N(Bhead$B$r;}$D$3$H$K$J$k!%%^!<%8(B |
655 $B$N7k2L$O!$$"$J$?$,4|BT$9$k$h$&$K(B\texttt{foo}$B%V%i%s%A>e$G(B1$B$D$N(Bhead$B$K$J$k!%(B | 656 $B$N7k2L$O!$$"$J$?$,4|BT$9$k$h$&$K(B\texttt{foo}$B%V%i%s%A>e$G(B1$B$D$N(Bhead$B$K$J$k!%(B |
656 | 657 |
657 %But if I'm working on the \texttt{bar} branch, and I merge work from | 658 %But if I'm working on the \texttt{bar} branch, and I merge work from |
658 %the \texttt{foo} branch, the result will remain on the \texttt{bar} | 659 %the \texttt{foo} branch, the result will remain on the \texttt{bar} |
659 %branch. | 660 %branch. |
660 %\interaction{branch-named.merge} | 661 %\interaction{branch-named.merge} |
661 | 662 |
662 $B$7$+$7!$;d$,(B\texttt{bar}$B%V%i%s%A$G:n6H$r$7$F$$$F!$(B\texttt{foo}$B%V%i%s%A$+(B | 663 $B$7$+$7!$;d$,(B\texttt{bar}$B%V%i%s%A$G:n6H$r$7$F$$$F!$(B\texttt{foo}$B%V%i%s%A$+(B |
663 $B$i%^!<%8$r9T$J$&$H!$@.2LJ*$O(B\texttt{bar}$B%V%i%s%A$K;D$k$3$H$K$J$k!%(B | 664 $B$i%^!<%8$r9T$&$H!$@.2LJ*$O(B\texttt{bar}$B%V%i%s%A$K;D$k$3$H$K$J$k!%(B |
664 \interaction{branch-named.merge} | 665 \interaction{branch-named.merge} |
665 | 666 |
666 %To give a more concrete example, if I'm working on the | 667 %To give a more concrete example, if I'm working on the |
667 %\texttt{bleeding-edge} branch, and I want to bring in the latest fixes | 668 %\texttt{bleeding-edge} branch, and I want to bring in the latest fixes |
668 %from the \texttt{stable} branch, Mercurial will choose the ``right'' | 669 %from the \texttt{stable} branch, Mercurial will choose the ``right'' |
669 %(\texttt{bleeding-edge}) branch name when I pull and merge from | 670 %(\texttt{bleeding-edge}) branch name when I pull and merge from |
670 %\texttt{stable}. | 671 %\texttt{stable}. |
671 | 672 |
672 $B$b$C$H6qBNE*$JNc$r5s$2$k$H!$$b$7;d$,(B\texttt{bleeding-edge}$B%V%i%s%A$G:n6H(B | 673 $B$b$C$H6qBNE*$JNc$r5s$2$k$H!$$b$7;d$,(B\texttt{bleeding-edge}$B%V%i%s%A$G:n6H(B |
673 $B$r$7$F$$$F!$(B\texttt{stable}$B%V%i%s%A$N?7$7$$=$@5$r<h$j9~$`$?$a$K(B | 674 $B$r$7$F$$$F!$(B\texttt{stable}$B%V%i%s%A$N?7$7$$=$@5$r<h$j9~$`$?$a$K(B |
674 \texttt{stable}$B$+$i(Bpull$B$H(Bmerge$B$r9T$J$&$H!$(BMercurial$B$O(B``$B@5$7$$(B''$B%V%i%s%AL>(B | 675 \texttt{stable}$B$+$i(Bpull$B$H(Bmerge$B$r9T$&$H!$(BMercurial$B$O(B``$B@5$7$$(B''$B%V%i%s%AL>(B |
675 (\texttt{bleeding-edge})$B$rA*$V!%(B | 676 (\texttt{bleeding-edge})$B$rA*$V!%(B |
676 | 677 |
677 %\section{Branch naming is generally useful} | 678 %\section{Branch naming is generally useful} |
678 \section{$B%V%i%s%A$KL>A0$rIU$1$k$3$H$OLr$KN)$D(B} | 679 \section{$B%V%i%s%A$KL>A0$rIU$1$k$3$H$OLr$KN)$D(B} |
679 | 680 |
708 %\end{codesample2} | 709 %\end{codesample2} |
709 | 710 |
710 $B6&M-%j%]%8%H%j$r;H$C$F:n6H$7$F$$$k>l9g!$(B\hook{pretxnchangegroup}$B%U%C%/$r(B | 711 $B6&M-%j%]%8%H%j$r;H$C$F:n6H$7$F$$$k>l9g!$(B\hook{pretxnchangegroup}$B%U%C%/$r(B |
711 $B@_Dj$9$k$3$H$G4V0c$C$?%V%i%s%AL>$r;}$D99?7$r%V%m%C%/$9$k$3$H$,$G$-$k!%$3(B | 712 $B@_Dj$9$k$3$H$G4V0c$C$?%V%i%s%AL>$r;}$D99?7$r%V%m%C%/$9$k$3$H$,$G$-$k!%$3(B |
712 $B$l$ONc$($P(B``$B:G@hC<(B''$B%V%i%s%A$+$i(B``$B0BDj(B''$B%V%i%s%A$XJQ99$r(Bpush$B$9$k$h$&$J4V(B | 713 $B$l$ONc$($P(B``$B:G@hC<(B''$B%V%i%s%A$+$i(B``$B0BDj(B''$B%V%i%s%A$XJQ99$r(Bpush$B$9$k$h$&$J4V(B |
713 $B0c$$$rKI$0$N$K%7%s%W%k$+$D8z2LE*$JJ}K!$G$"$k!%%U%C%/$O!$Nc$($P6&M-%j%]%8(B | 714 $B0c$$$rKI$0$N$K%7%s%W%k$+$D8z2LE*$JJ}K!$G$"$k!%%U%C%/$O!$6&M-%j%]%8%H%j$N(B |
714 $B%H%j$N(B \hgrc $B$K(B | 715 \hgrc $B$K(B |
715 \begin{codesample2} | 716 \begin{codesample2} |
716 [hooks] | 717 [hooks] |
717 pretxnchangegroup.branch = hg heads --template '{branches} ' | grep mybranch | 718 pretxnchangegroup.branch = hg heads --template '{branches} ' | grep mybranch |
718 \end{codesample2} | 719 \end{codesample2} |
719 $B$N$h$&$K5-=R$5$l$k!%(B | 720 $B$N$h$&$K5-=R$5$l$k!%(B |
720 | 721 |
721 | 722 |
722 %%% Local Variables: | 723 %%% Local Variables: |
723 %%% mode: yatex | 724 %%% mode: yatex |
724 %%% TeX-master: "00book" | 725 %%% TeX-master: "00book" |
725 %%% End: | 726 %%% End: |