# HG changeset patch # User Yoshiki Yazawa # Date 1202406537 -32400 # Node ID 91dda054ead0b69b60ce2298712525148797f47d # Parent b8105146706fa618ba3275427b9d8ddb11394354 more undo.tex diff -r b8105146706f -r 91dda054ead0 ja/undo.tex --- a/ja/undo.tex Fri Feb 08 02:14:00 2008 +0900 +++ b/ja/undo.tex Fri Feb 08 02:48:57 2008 +0900 @@ -282,24 +282,37 @@ \subsection{ファイル管理のミス} \label{sec:undo:mgmt} -The \hgcmd{revert} command is useful for more than just modified -files. It lets you reverse the results of all of Mercurial's file -management commands---\hgcmd{add}, \hgcmd{remove}, and so on. +%The \hgcmd{revert} command is useful for more than just modified +%files. It lets you reverse the results of all of Mercurial's file +%management commands---\hgcmd{add}, \hgcmd{remove}, and so on. + +\hgcmd{revert}コマンドは単に変更したファイルを戻すだけでなく, +\hgcmd{add},\hgcmd{remove}といったMercurialのファイル操作コマンドの結果 +を取り消すことができる. -If you \hgcmd{add} a file, then decide that in fact you don't want -Mercurial to track it, use \hgcmd{revert} to undo the add. Don't -worry; Mercurial will not modify the file in any way. It will just -``unmark'' the file. +%If you \hgcmd{add} a file, then decide that in fact you don't want +%Mercurial to track it, use \hgcmd{revert} to undo the add. Don't +%worry; Mercurial will not modify the file in any way. It will just +%``unmark'' the file. +%\interaction{daily.revert.add} + +\hgcmd{add}でファイルを追加した後で,Mercurialに追跡させる必要がないと分 +かった時,\hgcmd{revert}でaddを取り消すことができる.\hgcmd{revert}はファ +イルのマークを消すだけで,ファイルの中身は一切変更しないので心配する必要 +はない. \interaction{daily.revert.add} -Similarly, if you ask Mercurial to \hgcmd{remove} a file, you can use -\hgcmd{revert} to restore it to the contents it had as of the parent -of the working directory. -\interaction{daily.revert.remove} -This works just as well for a file that you deleted by hand, without -telling Mercurial (recall that in Mercurial terminology, this kind of -file is called ``missing''). -\interaction{daily.revert.missing} +%Similarly, if you ask Mercurial to \hgcmd{remove} a file, you can use +%\hgcmd{revert} to restore it to the contents it had as of the parent +%of the working directory. +%\interaction{daily.revert.remove} +%This works just as well for a file that you deleted by hand, without +%telling Mercurial (recall that in Mercurial terminology, this kind of +%file is called ``missing''). +%\interaction{daily.revert.missing} + + + If you revert a \hgcmd{copy}, the copied-to file remains in your working directory afterwards, untracked. Since a copy doesn't affect