# HG changeset patch # User Yoshiki Yazawa # Date 1206906586 -32400 # Node ID 2a8c05da3faefc10959e9362fd2691827f6816d4 # Parent 4ffdaa0773a368959d10666177a3f5138bd20de9 more mq.tex diff -r 4ffdaa0773a3 -r 2a8c05da3fae ja/mq.tex --- a/ja/mq.tex Sun Mar 30 18:34:59 2008 +0900 +++ b/ja/mq.tex Mon Mar 31 04:49:46 2008 +0900 @@ -677,47 +677,77 @@ %\subsection{Safety checks, and overriding them} \subsection{安全性チェックとオーバライド} -Several MQ commands check the working directory before they do -anything, and fail if they find any modifications. They do this to -ensure that you won't lose any changes that you have made, but not yet -incorporated into a patch. Figure~\ref{ex:mq:add} illustrates this; -the \hgxcmd{mq}{qnew} command will not create a new patch if there are -outstanding changes, caused in this case by the \hgcmd{add} of -\filename{file3}. +%Several MQ commands check the working directory before they do +%anything, and fail if they find any modifications. They do this to +%ensure that you won't lose any changes that you have made, but not yet +%incorporated into a patch.Figure~\ref{ex:mq:add} illustrates this; +%the \hgxcmd{mq}{qnew} command will not create a new patch if there are +%outstanding changes, caused in this case by the \hgcmd{add} of +%\filename{file3}. + +いくつかのMQコマンドは,実行時にまずワーキングディレクトリをチェックし, +変更がなされていたら終了するようになっている.これは,ユーザのまだパッチ +に取り込まれていない変更が失われないようにするためである. +図~\ref{ex:mq:add}はこれを説明したもので,\hgxcmd{mq}{qnew}コマンドは孤立 +した変更がある時に新たなパッチを生成しない.この例では,変更は +\hgcmd{add}による\filename{file3}の追加によって生まれている. \begin{figure}[ht] \interaction{mq.tutorial.add} - \caption{Forcibly creating a patch} +% \caption{Forcibly creating a patch} + \caption{パッチの強制的な生成} \label{ex:mq:add} \end{figure} -Commands that check the working directory all take an ``I know what -I'm doing'' option, which is always named \option{-f}. The exact -meaning of \option{-f} depends on the command. For example, -\hgcmdargs{qnew}{\hgxopt{mq}{qnew}{-f}} will incorporate any outstanding -changes into the new patch it creates, but -\hgcmdargs{qpop}{\hgxopt{mq}{qpop}{-f}} will revert modifications to any -files affected by the patch that it is popping. Be sure to read the -documentation for a command's \option{-f} option before you use it! +%Commands that check the working directory all take an ``I know what +%I'm doing'' option, which is always named \option{-f}. The exact +%meaning of \option{-f} depends on the command. For example, +%\hgcmdargs{qnew}{\hgxopt{mq}{qnew}{-f}} will incorporate any outstanding +%changes into the new patch it creates, but +%\hgcmdargs{qpop}{\hgxopt{mq}{qpop}{-f}} will revert modifications to any +%files affected by the patch that it is popping. Be sure to read the +%documentation for a command's \option{-f} option before you use it! + +ワーキングディレクトリのチェックを行なうコマンドは全て,上級者向けの強制 +オプション\option{-f}を持っている.\option{-f}の厳密な意味は,コマンドに +よって異なる.例えば\hgcmdargs{qnew}{\hgxopt{mq}{qnew}{-f}}は孤立した変 +更を新しいパッチに取り込むという意味だが, +\hgcmdargs{qpop}{\hgxopt{mq}{qpop}{-f}}は,ポップするパッチによるあらゆ +るファイルへの変更を取り消すという意味になる.\option{-f}オプションを使 +う時は必ず事前にコマンドのドキュメントを読んで確認するようにして欲しい. %\subsection{Working on several patches at once} \subsection{複数のパッチを一度に扱う} -The \hgxcmd{mq}{qrefresh} command always refreshes the \emph{topmost} -applied patch. This means that you can suspend work on one patch (by -refreshing it), pop or push to make a different patch the top, and -work on \emph{that} patch for a while. +%The \hgxcmd{mq}{qrefresh} command always refreshes the \emph{topmost} +%applied patch. This means that you can suspend work on one patch (by +%refreshing it), pop or push to make a different patch the top, and +%work on \emph{that} patch for a while. + +\hgxcmd{mq}{qrefresh}コマンドは\emph{最も上}に適用されたパッチに対してリ +フレッシュを行なう.これはリフレッシュによって1つのパッチに現在の作業をサ +スペンドしたり,別のトップパッチや一時的に作業するためパッチを作るために +ポップやプッシュができるということを意味する. -Here's an example that illustrates how you can use this ability. -Let's say you're developing a new feature as two patches. The first -is a change to the core of your software, and the second---layered on -top of the first---changes the user interface to use the code you just -added to the core. If you notice a bug in the core while you're -working on the UI patch, it's easy to fix the core. Simply -\hgxcmd{mq}{qrefresh} the UI patch to save your in-progress changes, and -\hgxcmd{mq}{qpop} down to the core patch. Fix the core bug, -\hgxcmd{mq}{qrefresh} the core patch, and \hgxcmd{mq}{qpush} back to the UI -patch to continue where you left off. +%Here's an example that illustrates how you can use this ability. +%Let's say you're developing a new feature as two patches. The first +%is a change to the core of your software, and the second---layered on +%top of the first---changes the user interface to use the code you just +%added to the core. If you notice a bug in the core while you're +%working on the UI patch, it's easy to fix the core. Simply +%\hgxcmd{mq}{qrefresh} the UI patch to save your in-progress changes, and +%\hgxcmd{mq}{qpop} down to the core patch. Fix the core bug, +%\hgxcmd{mq}{qrefresh} the core patch, and \hgxcmd{mq}{qpush} back to the UI +%patch to continue where you left off. + +この機能の使い方を示す例を示す.2つのパッチとして新しい機能を開発している +とする.最初のものはあなたのソフトウェアのコアを変更し,2番目のものは1番 +目のものの上に展開する,今追加したコアのコードを使ったユーザインタフェー +スだとする.UIパッチで作業中にコアのバグに気付いたとすると,簡単にコアの +修正は行なえる.単純に\hgxcmd{mq}{qrefresh}によって進行中のUIパッチをセー +ブし,\hgxcmd{mq}{qpop}によってコアパッチへ遡る.コアのバグを修正した後 +に\hgxcmd{mq}{qrefresh}をコアパッチについて行ない,\hgxcmd{mq}{qpush}で +UIパッチに戻って作業を続ける. %\section{More about patches} \section{さらにパッチについて}