Mercurial > hgbook
changeset 324:7dc8a24c70f4
more mq.tex
author | Yoshiki Yazawa <yaz@cc.rim.or.jp> |
---|---|
date | Fri, 28 Mar 2008 01:13:26 +0900 |
parents | 2d1054e1de5b |
children | a8269a1b9164 |
files | ja/mq.tex ja/todo.txt |
diffstat | 2 files changed, 81 insertions(+), 39 deletions(-) [+] |
line wrap: on
line diff
--- a/ja/mq.tex Thu Mar 27 22:11:00 2008 +0900 +++ b/ja/mq.tex Fri Mar 28 01:13:26 2008 +0900 @@ -146,54 +146,96 @@ \subsection{patchwork quilt$B$+$i(BMercurial Queues$B$X(B} \label{sec:mq:quilt-mq} -In mid-2005, Chris Mason took the features of quilt and wrote an -extension that he called Mercurial Queues, which added quilt-like -behaviour to Mercurial. +%In mid-2005, Chris Mason took the features of quilt and wrote an +%extension that he called Mercurial Queues, which added quilt-like +%behaviour to Mercurial. + +2005$BG/$NCf:"(BChris Mason$B$O!$(Bquilt$B$N5!G=$r<h$jF~$l$F!$(BMercurial$B$K(Bquilt$B$N$h(B +$B$&$JF0:n$rDI2C$9$k(BMercurial Queues$B$H$$$&%(%/%9%F%s%7%g%s$r=q$$$?!%(B + +%The key difference between quilt and MQ is that quilt knows nothing +%about revision control systems, while MQ is \emph{integrated} into +%Mercurial. Each patch that you push is represented as a Mercurial +%changeset. Pop a patch, and the changeset goes away. -The key difference between quilt and MQ is that quilt knows nothing -about revision control systems, while MQ is \emph{integrated} into -Mercurial. Each patch that you push is represented as a Mercurial -changeset. Pop a patch, and the changeset goes away. +quilt$B$H(BMQ$B$N0c$$$O!$(Bquilt$B$O%j%S%8%g%s4IM}%7%9%F%`$K$D$$$F2?$b4XCN$7$J$$$N(B +$B$KBP$7$F!$(BMQ$B$O(BMercurial$B$KE}9g$5$l$F$$$k$3$H$G$"$k!%%W%C%7%e$7$?8D!9$N%Q%C(B +$B%A$O(BMercurial$B$N%A%'%s%8%;%C%H$H$7$FI=8=$5$l$k!%%Q%C%A$r%]%C%W$9$k$H!$%A%'(B +$B%s%8%;%C%H$O>C$($F$J$/$J$k!%(B -Because quilt does not care about revision control tools, it is still -a tremendously useful piece of software to know about for situations -where you cannot use Mercurial and MQ. +%Because quilt does not care about revision control tools, it is still +%a tremendously useful piece of software to know about for situations +%where you cannot use Mercurial and MQ. + +quilt$B$O%j%S%8%g%s4IM}%D!<%k$HL54X78$KMxMQ2DG=$J$?$a!$(BMercurial$B$H(BMQ$B$,;H$((B +$B$J$$>u67$G$O0MA3$H$7$FHs>o$KM-1W$J%D!<%k$G$"$k$3$H$O5-21$KN1$a$F$*$/$Y$-(B +$B$G$"$k!%(B %\section{The huge advantage of MQ} \section{MQ$B$NBg$-$JMxE@(B} -I cannot overstate the value that MQ offers through the unification of -patches and revision control. +%I cannot overstate the value that MQ offers through the unification of +%patches and revision control. + +MQ$B$,%Q%C%A$H%j%S%8%g%s%3%s%H%m!<%k$NE}9g$K$h$C$F$b$?$i$92ACM$r8XD%$9$k$o(B +$B$1$K$O$$$+$J$$!%(B + +%A major reason that patches have persisted in the free software and +%open source world---in spite of the availability of increasingly +%capable revision control tools over the years---is the \emph{agility} +%they offer. -A major reason that patches have persisted in the free software and -open source world---in spite of the availability of increasingly -capable revision control tools over the years---is the \emph{agility} -they offer. +$B;~$rDI$&Kh$K%j%S%8%g%s%3%s%H%m!<%k%D!<%k$NMxMQ$,9-$,$C$F$$$k$K$b$+$+$o$i(B +$B$:!$%U%j!<%=%U%H$H%*!<%W%s%=!<%9$N@$3&$K%Q%C%A$,B8:_$9$kBg$-$JM}M3$O$=$N(B +\emph{$B5!IR$5(B}$B$K$"$k!%(B -Traditional revision control tools make a permanent, irreversible -record of everything that you do. While this has great value, it's -also somewhat stifling. If you want to perform a wild-eyed -experiment, you have to be careful in how you go about it, or you risk -leaving unneeded---or worse, misleading or destabilising---traces of -your missteps and errors in the permanent revision record. +%Traditional revision control tools make a permanent, irreversible +%record of everything that you do. While this has great value, it's +%also somewhat stifling. If you want to perform a wild-eyed +%experiment, you have to be careful in how you go about it, or you risk +%leaving unneeded---or worse, misleading or destabilising---traces of +%your missteps and errors in the permanent revision record. + +$BEAE}E*$J%j%S%8%g%s%3%s%H%m!<%k%D!<%k$O!$9T$J$C$?A`:n$N1J5WE*$GIT2D5UE*$J(B +$B5-O?$r;D$9!%$3$l$K$OBg$-$J2ACM$,$"$k0lJ}$G!$5g6~$K46$8$k$3$H$b$"$k!%$b$7(B +$B2a7c$J<B83$r$9$k$N$G$"$l$P!$$I$N$h$&$K?J$a$k$+?5=E$K$9$kI,MW$,$"$k!%$5$b(B +$B$J$1$l$P!$ITMW$J!$$"$k$$$O8m2r$r>7$$$?$j!$0BDj@-$rB;$J$&%H%l!<%9$H%(%i!<(B +$B$r1J5WE*$J%j%S%8%g%sMzNr$K;D$9$3$H$K$J$k!%(B -By contrast, MQ's marriage of distributed revision control with -patches makes it much easier to isolate your work. Your patches live -on top of normal revision history, and you can make them disappear or -reappear at will. If you don't like a patch, you can drop it. If a -patch isn't quite as you want it to be, simply fix it---as many times -as you need to, until you have refined it into the form you desire. +%By contrast, MQ's marriage of distributed revision control with +%patches makes it much easier to isolate your work. Your patches live +%on top of normal revision history, and you can make them disappear or +%reappear at will. If you don't like a patch, you can drop it. If a +%patch isn't quite as you want it to be, simply fix it---as many times +%as you need to, until you have refined it into the form you desire. + +$BBP>NE*$K!$(BMQ$B$K$h$kJ,;6%j%S%8%g%s%3%s%H%m!<%k$H%Q%C%A$N7k9g$O!$:n6H$r3VN%(B +$B$9$k$3$H$rMZ$+$KMF0W$K$9$k!%%Q%C%A$ODL>o$N%j%S%8%g%sMzNr$N>e$K>h$C$F$*$j!$(B +$BK>$`$h$&$K>CLG$5$;$?$j:F8=$5$;$k$3$H$,$G$-$k!%%Q%C%A$r5$$KF~$i$J$1$l$P!$(B +$B$3$l$r4~5Q$9$k$3$H$b$G$-$k!%%Q%C%A$,$"$J$?$NK>$`$h$&$J$b$N$G$J$1$l$P!$4u(B +$BK>DL$j$K$J$k$^$G2?EY$G$b4JC1$K=$@5$9$k$3$H$,$G$-$k!%(B -As an example, the integration of patches with revision control makes -understanding patches and debugging their effects---and their -interplay with the code they're based on---\emph{enormously} easier. -Since every applied patch has an associated changeset, you can use -\hgcmdargs{log}{\emph{filename}} to see which changesets and patches -affected a file. You can use the \hgext{bisect} command to -binary-search through all changesets and applied patches to see where -a bug got introduced or fixed. You can use the \hgcmd{annotate} -command to see which changeset or patch modified a particular line of -a source file. And so on. +%As an example, the integration of patches with revision control makes +%understanding patches and debugging their effects---and their +%interplay with the code they're based on---\emph{enormously} easier. +%Since every applied patch has an associated changeset, you can use +%\hgcmdargs{log}{\emph{filename}} to see which changesets and patches +%affected a file. You can use the \hgext{bisect} command to +%binary-search through all changesets and applied patches to see where +%a bug got introduced or fixed. You can use the \hgcmd{annotate} +%command to see which changeset or patch modified a particular line of +%a source file. And so on. + +$BNc$($P!$%j%S%8%g%s%3%s%H%m!<%k$X$N%Q%C%A$NE}9g$O!$%Q%C%A$rM}2r$7!$$=$N1F(B +$B6A!$0M$C$FN)$D%Y!<%9%3!<%I$H$NAj8_:nMQ$r%G%P%C%0$9$k$3$H$r2DG=$K$9$k!%E,(B +$BMQ$5$l$?%Q%C%A$O!$4XO"$E$1$i$l$?%A%'%s%8%;%C%H$r;}$D$?$a!$(B +\hgcmdargs{log}{\emph{filename}}$B$K$h$C$F$I$N%A%'%s%8%;%C%H$H%Q%C%A$,%U%!(B +$B%$%k$K1F6A$rM?$($F$$$k$+D4$Y$k$3$H$,$G$-$k!%(B\hgext{bisect}$B%3%^%s%I$GA4$F(B +$B$N%A%'%s%8%;%C%H$HE,MQ$5$l$?%Q%C%A$KBP$7$F%P%$%J%j%5!<%A$r9T$J$$!$$I$3$G(B +$B%P%0$,:.F~$7$?$+!$$"$k$$$O=$@5$5$l$?$+$rD4$Y$k$3$H$,$G$-$k!%(B +\hgcmd{annotate}$B%3%^%s%I$G$I$N%A%'%s%8%;%C%H$+%Q%C%A$,%=!<%9%U%!%$%k$NFC(B +$BDj$N9T$rJQ99$7$?$+8+$k$3$H$,$G$-$k!%(B + %\section{Understanding patches} \section{$B%Q%C%A$H$O2?$+(B}