Hi Tommy,

Here's my improvements on Eric's patch for issue434.  I think (with a bit
of review) this will be appropriate for darcs-stable.  Eric, if you want
to take a look at it, I think it's *definitely* appropriate for
darcs-unstable.

David

Thu Apr 19 13:00:48 PDT 2007  Eric Kow <[EMAIL PROTECTED]>
  * Add tests specifically for applying patches to the working dir (issue434).

Thu Apr 19 13:05:58 PDT 2007  Eric Kow <[EMAIL PROTECTED]>
  * Apply patches 'tolerantly' to the working directory (issue434).
  
  If there are any exceptions applying a patch to the working directory, catch
  the exceptions, emit a pretty warning and move on.  This is meant to ease
  the scenario where the user is pulling in a large patch, but there is a
  permissions error (or something similar) in the working directory.
  
  Without this patch, darcs typically dies and leaves the working directory in
  a 'corrupted' state.  The corruption is relatively minor in that patches and
  pristine are perfectly fine.  The problem is that the user has large portions
  of the patch still upapplied and when he does a darcs whatsnew, gets a mass
  of seemingly incomprehensible goop (the inverse of the unapplied changes)
  mixed in with his changes.  We reduce the incomprehensible goop effect by
  catching exceptions so that darcs can continue to apply as much of the patch
  as it can.

Fri Apr 20 17:19:33 PDT 2007  David Roundy <[EMAIL PROTECTED]>
  * reenable --quiet mode in apply.

New patches:

[Add tests specifically for applying patches to the working dir (issue434).
Eric Kow <[EMAIL PROTECTED]>**20070419200048] 
<
> {
addfile ./tests/workingdir.pl
hunk ./tests/workingdir.pl 1
+#!/usr/bin/env perl
+
+# test for working dir woes
+
+use Test::More qw/no_plan/;
+use lib ('lib/perl');
+use Test::Darcs;
+use strict;
+use Cwd;
+
+sub reset_chmod {
+  my $d = shift;
+  `chmod -R u+w $d` if (-d $d);
+}
+
+# note that we deliberately choose something other than temp
+# so as to avoid interfering with other tests if something
+# goes wrong and we fail to reset the permissions.
+reset_chmod('wtemp0');
+reset_chmod('wtemp1');
+reset_chmod('wtemp2');
+
+cleanup 'wtemp0';
+cleanup 'wtemp1';
+cleanup 'wtemp2';
+mkdir 'wtemp0';
+chdir 'wtemp0';
+darcs 'init';
+mkdir 'a';
+`touch a/x`;
+darcs 'add a';
+darcs 'add a/x';
+darcs 'record -am "a" --author me';
+chdir '..';
+
+darcs 'get wtemp0 wtemp1';
+darcs 'get wtemp1 wtemp2';
+chdir 'wtemp1';
+darcs 'mv a/x a/y';
+darcs 'record -am "x to y" --author me';
+`touch b`;
+darcs 'add b';
+darcs 'record -am "b" --author me';
+chdir '../wtemp2';
+# try to move a file that we don't have the right to do
+`chmod u-w a`;
+darcs 'pull -a';
+ok((-e 'b'), "managed to do pull b despite problems with x to y");
+
+
+reset_chmod('wtemp0');
+reset_chmod('wtemp1');
+reset_chmod('wtemp2');
+cleanup('wtemp0');
+cleanup('wtemp1');
+cleanup('wtemp2');
}
[Apply patches 'tolerantly' to the working directory (issue434).
Eric Kow <[EMAIL PROTECTED]>**20070419200558
 
 If there are any exceptions applying a patch to the working directory, catch
 the exceptions, emit a pretty warning and move on.  This is meant to ease
 the scenario where the user is pulling in a large patch, but there is a
 permissions error (or something similar) in the working directory.
 
 Without this patch, darcs typically dies and leaves the working directory in
 a 'corrupted' state.  The corruption is relatively minor in that patches and
 pristine are perfectly fine.  The problem is that the user has large portions
 of the patch still upapplied and when he does a darcs whatsnew, gets a mass
 of seemingly incomprehensible goop (the inverse of the unapplied changes)
 mixed in with his changes.  We reduce the incomprehensible goop effect by
 catching exceptions so that darcs can continue to apply as much of the patch
 as it can.
] 
<
> {
hunk ./Apply.lhs 50
 import Repository ( PatchSet, withRepoLock, amInRepository,
                     get_unrecorded, slurp_pending, slurp_recorded,
                     with_new_pending, sync_repo, read_repo, updateInventory,
+                    applyToWorking,
                     applyToPristine,
                   )
 import Patch ( Patch, patch2patchinfo, invert, list_touched_files,
hunk ./Apply.lhs 56
                join_patches, unjoin_patches, null_patch,
              )
-import qualified Patch (apply)
 import PatchInfo ( human_friendly )
 import SlurpDirectory ( wait_a_moment, co_slurp, )
 import FastPackedString ( readFilePS, packString, unpackPS, hGetContentsPS,
hunk ./Apply.lhs 193
           fail ("Error applying patch to recorded!\nRunning 'darcs repair' on the target repository may help.\n" ++ show e)
       wait_a_moment -- so work will be more recent than rec
       updateInventory repository tokens
-      Patch.apply opts True pw_resolved `catch` \e ->
+      applyToWorking repository opts pw_resolved `catch` \e ->
           fail ("Error applying patch to working dir:\n" ++ show e)
     sync_repo repository
     putStrLn "Finished applying..."
hunk ./DarcsIO.lhs 37
 
 \begin{comment}
 \begin{code}
-module DarcsIO ( ReadableDirectory(..), WriteableDirectory(..),
+module DarcsIO ( ReadableDirectory(..), WriteableDirectory(..), TolerantIO(..),
                ) where
 
hunk ./DarcsIO.lhs 40
+import Prelude hiding ( catch )
 import Data.List ( isSuffixOf )
hunk ./DarcsIO.lhs 42
-import System.IO.Error ( isDoesNotExistError )
+import System.IO.Error ( isDoesNotExistError, isPermissionError )
+import Control.Exception ( catch, catchJust, ioErrors )
 import Control.Monad.Error
 import System.Directory ( getDirectoryContents, createDirectory,
                           removeDirectory, removeFile,
hunk ./DarcsIO.lhs 54
 import FastPackedString ( PackedString, readFilePS, linesPS,
                           unlinesPS, nilPS, packString, unpackPS,
                         )
-import DarcsUtils ( withCurrentDirectory )
+import DarcsUtils ( withCurrentDirectory, prettyException )
 import Printer ( Doc, renderPS )
 import FileName ( FileName, fn2fp, fp2fn )
 import Lock ( writeBinFile, readBinFile, writeAtomicFilePS )
hunk ./DarcsIO.lhs 87
     mWriteFilePSs f ss = mWriteFilePS f (unlinesPS ss)
     mCreateDirectory :: FileName -> m ()
     mRemoveDirectory :: FileName -> m ()
-    -- | If the directory is non-empty, do not treat it as an error
-    --   nor remove it.  This may print a warning if the Bool (for
-    --   quiet) is 'False'.  Note: this may not always be implemented,
-    --   in which case it is the same as 'mRemoveDirectory'
-    mRemoveDirectoryIfPossible :: Bool -> FileName -> m ()
-    mRemoveDirectoryIfPossible _ d = mRemoveDirectory d
     mWriteDoc :: FileName -> Doc -> m ()
     mWriteDoc f d = mWriteFilePS f (renderPS d)
     mCreateFile :: FileName -> m ()
hunk ./DarcsIO.lhs 119
     mCreateDirectory = createDirectory . fn2fp
     mRemoveFile = removeFile . fn2fp
     mRemoveDirectory = removeDirectory . fn2fp
-    mRemoveDirectoryIfPossible quiet d =
-      (mRemoveDirectory d)
-      `catch` (\e -> if "(Directory not empty)" `isSuffixOf` (show e)
-                     then when (not quiet) $ putStrLn $
-                            "Warning: Not deleting " ++
-                            (fn2fp d) ++ " because it is non-empty."
-                     else ioError e)
-    mRename a b = (renameDirectory x y `mplus` renameFile x y)
+    mRename a b = catchJust ioErrors
+                  (renameDirectory x y `mplus` renameFile x y)
                   -- We need to catch does not exist errors, since older
                   -- versions of darcs allowed users to rename nonexistent
                   -- files.  :(
hunk ./DarcsIO.lhs 124
-                  `catch` (\e -> if isDoesNotExistError e
+                  (\e -> if isDoesNotExistError e
                                  then return ()
                                  else ioError e)
hunk ./DarcsIO.lhs 127
-        where x = fn2fp a
-              y = fn2fp b
+      where x = fn2fp a
+            y = fn2fp b
+
+data TolerantIO a = TIO { runTolerantly :: IO a }
+
+instance Monad TolerantIO where
+   (TIO io) >>= f = TIO $ io >>= (\x -> runTolerantly $ f x)
+   (TIO io) >> f  = TIO $ io >> runTolerantly f
+   return x = TIO $ return x
+   fail x = TIO $ fail x
+
+instance MonadPlus TolerantIO where
+   mzero = TIO $ mzero
+   mplus (TIO a) (TIO b) = TIO $ mplus a b
+
+instance ReadableDirectory TolerantIO where
+    mDoesDirectoryExist d = TIO $ mDoesDirectoryExist d
+    mDoesFileExist f = TIO $ mDoesFileExist f
+    mIsFileExecutable f = TIO $ mIsFileExecutable f
+    mInCurrentDirectory i (TIO j) = TIO $ mInCurrentDirectory i j
+    mGetDirectoryContents = TIO mGetDirectoryContents
+    mReadBinFile f = TIO $ mReadBinFile f
+    mReadFilePS f = TIO $ mReadFilePS f
+
+instance WriteableDirectory TolerantIO where
+     mWithCurrentDirectory f (TIO m) = TIO $ mWithCurrentDirectory f m
+     mSetFileExecutable f e = warning $ mSetFileExecutable f e
+     mWriteBinFile f s = warning $ mWriteBinFile f s
+     mWriteFilePS f s = warning $ mWriteFilePS f s
+     mCreateDirectory d = warning $ mCreateDirectory d
+     mRemoveFile f = warning $ mRemoveFile f
+     mRemoveDirectory d = warning $ catchJust ioErrors
+                                 (mRemoveDirectory d)
+                                 (\e -> when ("(Directory not empty)" `isSuffixOf` (show e)) $
+                                        ioError $ userError $
+                                         "Not deleting " ++ fn2fp d ++ " because it is not empty.")
+     mRename a b = warning $ catchJust ioErrors
+                          (mRename a b)
+                          (\e -> case () of
+                                 _ | isPermissionError e -> ioError $ userError $
+                                       couldNotRename ++ "."
+                                   | isDoesNotExistError e -> ioError $ userError $
+                                       couldNotRename ++ " because " ++ x ++ " does not exist."
+                                   | otherwise -> ioError e
+                          )
+       where
+        x = fn2fp a
+        y = fn2fp b
+        couldNotRename = "Could not rename " ++ x ++ " to " ++ y
+
+warning :: IO () -> TolerantIO ()
+warning io = TIO $ catch io $ \e -> putStrLn $ "Warning: " ++ prettyException e
 \end{code}
 \end{comment}
 
hunk ./PatchApply.lhs 28
        where
 
 import Prelude hiding ( catch, pi )
-import DarcsFlags ( DarcsFlag( SetScriptsExecutable, Quiet ) )
+import DarcsFlags ( DarcsFlag( SetScriptsExecutable ) )
 import FastPackedString ( PackedString, packString, splitPS, concatPS,
                           breakPS, nullPS, nilPS, linesPS, takePS,
                           unlinesPS,
hunk ./PatchApply.lhs 142
                          else fail $ "binary patch to " ++ fn2fp f
                                   ++ " couldn't apply."
 apply _ _ (DP d AddDir) = mCreateDirectory d
-apply opts True (DP d RmDir) = mRemoveDirectoryIfPossible quiet d
-                               where quiet = Quiet `elem` opts
 apply _ _ (DP d RmDir) = mRemoveDirectory d
 
 apply _ _ (Move f f') = mRename f f'
hunk ./Pull.lhs 47
                     slurp_recorded, slurp_recorded_and_unrecorded,
                     read_repo, absolute_dir, get_unrecorded,
                     with_new_pending, read_pending, sync_repo,
+                    applyToWorking,
                     applyToPristine, writePatch, updateInventory,
                   )
 import Patch ( Patch, join_patches, merge, patch2patchinfo,
hunk ./Pull.lhs 53
                unjoin_patches, list_touched_files,
                invert, list_conflicted_files, null_patch,
-               apply,
              )
 import SelectChanges ( promptChar )
 import PatchInfo ( PatchInfo, human_friendly, showPatchInfo )
hunk ./Pull.lhs 185
           updateInventory repository patchTokens
           -- so work will be more recent than rec:
           revertable wait_a_moment
-          revertable $ apply opts True pw_resolved `catch` \e ->
-              fail ("Error applying patch to working dir:\n" ++ show e)
+          revertable $ applyToWorking repository opts pw_resolved `catch` \e ->
+               fail ("Error applying patch to working dir:\n" ++ show e)
       sync_repo repository
       putInfo $ text "Finished pulling and applying."
           where fromMaybePatch Nothing = null_patch
hunk ./Replace.lhs 29
 import DarcsArguments
 import Repository ( withRepoLock,
                     slurp_pending, add_to_pending,
+                    applyToWorking,
                   )
 import DarcsRepo ( am_in_repo, slurp_recorded_and_unrecorded
                  )
hunk ./Replace.lhs 33
-import Patch ( apply, apply_to_slurpy, tokreplace, force_replace_slurpy,
+import Patch ( apply_to_slurpy, tokreplace, force_replace_slurpy,
                join_patches, Patch,
              )
 import SlurpDirectory ( slurp_hasfile, Slurpy )
hunk ./Replace.lhs 140
   (_, work) <- slurp_recorded_and_unrecorded "."
   cur <- slurp_pending repository
   ps_and_pswork <- catMaybes `liftM` sequence (map (repl toks cur work) fs)
-  apply opts True (join_patches $ snd $ unzip ps_and_pswork) `catch` \e ->
+  applyToWorking repository opts (join_patches $ snd $ unzip ps_and_pswork) `catch` \e ->
       fail $ "Can't do replace on working!\n"
           ++ "Perhaps one of the files already contains '"++ new++"'?\n"
           ++ show e
hunk ./Repository.lhs 32
 #endif
                     PatchToken, patchTokenToPatchFile,
                     writePatch, updateInventory, unrevertUrl,
+                    applyToWorking,
                     applyToPristine, patchSetToPatches,
                     PatchSet
                   ) where
hunk ./Repository.lhs 52
                               WorkDir, UMask) )
 import PatchInfo ( PatchInfo )
 import Patch ( Patch, flatten, join_patches, reorder_and_coalesce,
+               apply,
                apply_to_slurpy, gzReadPatchFileLazily )
 import Diff ( smart_diff )
 import PatchSet ( PatchSet )
hunk ./Repository.lhs 63
 #ifdef HAVEWX
 import Lock ( takeLock, releaseLock, withLockCanFail )
 #endif
-
+import DarcsIO ( runTolerantly )
 #include "impossible.h"
 
 data Repository = Repo !String !RepoFormat !RepoType
hunk ./Repository.lhs 241
 unrevertUrl (Repo r _ (DarcsRepository _)) = r ++ "/_darcs/patches/unrevert"
 unrevertUrl (Repo r _ GitRepository) = r ++ "/.git/darcs-unrevert"
 
+applyToWorking :: Repository -> [DarcsFlag] -> Patch -> IO ()
+applyToWorking (Repo r _ (DarcsRepository _)) opts patch =
+    withCurrentDirectory r $ runTolerantly $ apply opts True patch
+applyToWorking (Repo _ _ GitRepository) _ _ = return ()
+
+
 applyToPristine :: Repository -> Patch -> IO ()
 applyToPristine (Repo r _ (DarcsRepository p)) patch =
     withCurrentDirectory r $ applyPristine p patch
hunk ./Resolve.lhs 29
 import DarcsArguments ( DarcsFlag( AnyOrder ),
                         ignoretimes, verbose, working_repo_dir, umask_option,
                       )
-import Repository ( withRepoLock, amInRepository,
+import Repository ( withRepoLock, amInRepository, applyToWorking,
                     read_repo, sync_repo, get_unrecorded, with_new_pending,
                     )
hunk ./Resolve.lhs 32
-import Patch ( join_patches, invert, apply, is_null_patch )
+import Patch ( join_patches, invert, is_null_patch )
 import Resolution ( patchset_conflict_resolutions )
 import SelectChanges ( promptChar )
 #include "impossible.h"
hunk ./Resolve.lhs 85
                          ("This will trash any unrecorded changes"++
                           " in the working directory.\nAre you sure? ") "yn"
                  when (yorn /= 'y') $ exitWith ExitSuccess
-                 apply opts True (invert p) `catch` \e ->
+                 applyToWorking repository opts (invert p) `catch` \e ->
                     bug ("Can't undo pending changes!" ++ show e)
                  sync_repo repository
   withSignalsBlocked $ with_new_pending repository res $
hunk ./Resolve.lhs 89
-      apply opts True res `catch` \e ->
+      applyToWorking repository opts res `catch` \e ->
       bug ("Problem resolving conflicts in resolve!" ++ show e)
   putStrLn "Finished resolving."
 resolve_cmd _ _ = impossible
hunk ./Revert.lhs 37
 import Repository ( withRepoLock,
                     get_unrecorded,
                     with_new_pending, sync_repo,
+                    applyToWorking,
                     amInRepository, slurp_recorded_and_unrecorded,
                   )
 import Patch ( join_patches, invert, is_null_patch,
hunk ./Revert.lhs 41
-               apply, flatten, apply_to_filepaths )
+               flatten, apply_to_filepaths )
 import SelectChanges ( with_selected_last_changes_to_files )
 import TouchesFiles ( choose_touching )
 import Unrevert ( write_unrevert )
hunk ./Revert.lhs 118
              write_unrevert (join_patches skipped') p rec
              withSignalsBlocked $
                  with_new_pending repository (join_patches skipped')$
-                 apply opts True (invert $ join_patches p) `catch` \e ->
+                 applyToWorking repository opts (invert $ join_patches p) `catch` \e ->
                  fail ("Unable to apply inverse patch!" ++ show e)
   sync_repo repository
   putStrLn "Finished reverting."
hunk ./Unrecord.lhs 36
 import Match ( first_match, match_first_patchset,
              )
 import Repository ( PatchSet, withRepoLock, slurp_recorded,
+                    applyToWorking,
                     get_unrecorded,
                     read_pending, with_new_pending, sync_repo,
                   )
hunk ./Unrecord.lhs 47
                  )
 import Pristine ( identifyPristine, applyPristine )
 import Patch ( Patch, invert, patch2patchinfo,
-               join_patches, commute, flatten, null_patch, apply
+               join_patches, commute, flatten, null_patch,
              )
 import PatchInfo ( PatchInfo )
 import Depends ( deep_optimize_patchset, commute_to_end, get_common_and_uncommon )
hunk ./Unrecord.lhs 398
            pris <- identifyPristine
            applyPristine pris (invert $ join_patches ps) `catch` \e ->
                fail ("Unable to apply inverse patch!\n" ++ show e)
-           apply opts True (invert p_after_pending) `catch` \e ->
+           applyToWorking repository opts (invert p_after_pending) `catch` \e ->
                fail ("Couldn't undo patch in working dir.\n" ++ show e)
         sync_repo repository
         logMessage $ "Finished " ++ present_participle cmdname ++ "."
hunk ./Unrevert.lhs 37
                     sync_repo,
                     read_repo, amInRepository,
                     slurp_recorded_and_unrecorded,
+                    applyToWorking,
                   )
hunk ./Unrevert.lhs 39
-import Patch ( Patch, join_patches, apply,
+import Patch ( Patch, join_patches,
                patch2patchinfo, commute, namepatch, flatten_to_primitives,
              )
 import SelectChanges ( with_selected_changes_to_files )
hunk ./Unrevert.lhs 111
                          Nothing -> join_patches p
                          Just pending -> join_patches (pending : p)
         withSignalsBlocked $ with_new_pending repository pend_and_p $
-          do apply opts True (join_patches p) `catch` \e ->
+          do applyToWorking repository opts (join_patches p) `catch` \e ->
                  fail ("Error applying unrevert to working directory...\n"
                     ++ show e)
              write_unrevert pend_and_p skipped rec
hunk ./tests/pull.pl 127
 
 CREATE_DIR_ERROR: {
    my $test_name = "when a patch creating a directory is attempted to be applied
-       when an existing directory, exists, an error is reported.";
+       when an existing directory, exists, a warning is raised, but the pull
+       succeeds.";
    mkdir 'temp1/newdir';
    chdir 'templ/';
    ok((chdir 'temp1/'), "chdir succeeds");;
hunk ./tests/pull.pl 137
    ok((chdir '../temp2'), "chdir succeeds");;
    mkdir 'newdir';
    my $out = darcs('pull -a ../temp1');
-   like($out, qr/fail/i, $test_name);
+   like($out, qr/Warning: /i, $test_name);
+   like($out, qr/Finished pulling/i, $test_name);
    {
       local $TODO = 'awaiting attention from a Haskell coder.';
       like($out, qr/newdir/i, "...and report the name if the directory involved");
hunk ./tests/rmdir.pl 88
 # get temp2 and add some extra stuff to the directory
 setupTemp1Temp2;
 checkTemp2Prepull;
-like(darcs(qw(pull -a --repodir=temp2)), qr(non-empty));
+like(darcs(qw(pull -a --repodir=temp2)), qr(not empty));
 checkTemp2Postpull;
 # same test as above, but be vewy vewy quiet
 setupTemp1Temp2;
hunk ./tests/rmdir.pl 93
 checkTemp2Prepull;
-unlike(darcs(qw(pull -a --repodir=temp2 --quiet)), qr(.+));
+{
+  local $TODO="Make --quiet work for applying to working dir again";
+  unlike(darcs(qw(pull -a --repodir=temp2 --quiet)), qr(.+));
+}
 checkTemp2Postpull;
 # make sure that a messed up pristine still creates an error
 setupTemp1Temp2;
}
[reenable --quiet mode in apply.
David Roundy <[EMAIL PROTECTED]>**20070421001933] 
<
> {
hunk ./Check.lhs 114
             case patch2patchinfo chk of
             Just chtg -> do
                 putVerbose $ text "I am checking from a checkpoint."
-                apply_patches_with_feedback [] False feedback putInfo
+                apply_patches_with_feedback [] feedback putInfo
                          $ (chtg, Just chk)
                     : reverse (concat $ get_patches_beyond_tag chtg patches)
             Nothing -> impossible
hunk ./Check.lhs 118
-        Nothing -> apply_patches_with_feedback [] False feedback putInfo $
+        Nothing -> apply_patches_with_feedback [] feedback putInfo $
                    reverse $ concat patches
     is_same <-
         withCurrentDirectory cwd $ (identifyPristine >>= checkPristine chd)
hunk ./DarcsIO.lhs 37
 
 \begin{comment}
 \begin{code}
-module DarcsIO ( ReadableDirectory(..), WriteableDirectory(..), TolerantIO(..),
+{-# OPTIONS -fglasgow-exts #-}
+module DarcsIO ( ReadableDirectory(..), WriteableDirectory(..),
+                 TolerantIO, runTolerantly, runSilently,
                ) where
 
 import Prelude hiding ( catch )
hunk ./DarcsIO.lhs 132
       where x = fn2fp a
             y = fn2fp b
 
-data TolerantIO a = TIO { runTolerantly :: IO a }
+data TolerantIO a where
+    TIO :: IO a -> TolerantIO a
+    TWarning :: IO () -> TolerantIO ()
+    TThen :: TolerantIO a -> (a -> TolerantIO b) -> TolerantIO b
+    TCatch :: TolerantIO a -> TolerantIO a -> TolerantIO a
+    TNested :: (IO a -> TolerantIO b) -> TolerantIO a -> TolerantIO b
+
+warning :: IO () -> TolerantIO ()
+warning io = TWarning io
+
+runTolerantly :: TolerantIO a -> IO a
+runTolerantly (TIO io) = io
+runTolerantly (TWarning io) =
+    io `catch` \e -> putStrLn $ "Warning: " ++ prettyException e
+runTolerantly (TThen io tio) = runTolerantly io >>= runTolerantly . tio
+runTolerantly (TCatch a b) = runTolerantly a `catch` \_ -> runTolerantly b
+runTolerantly (TNested w b) = runTolerantly $ w (runTolerantly b)
+
+runSilently :: TolerantIO a -> IO a
+runSilently (TIO io) = io
+runSilently (TWarning io) = io `catch` \_ -> return ()
+runSilently (TThen io tio) = runSilently io >>= runSilently . tio
+runSilently (TCatch a b) = runSilently a `catch` \_ -> runSilently b
+runSilently (TNested w b) = runSilently $ w (runSilently b)
 
 instance Monad TolerantIO where
hunk ./DarcsIO.lhs 158
-   (TIO io) >>= f = TIO $ io >>= (\x -> runTolerantly $ f x)
-   (TIO io) >> f  = TIO $ io >> runTolerantly f
+   tio >>= f = TThen tio f
    return x = TIO $ return x
    fail x = TIO $ fail x
 
hunk ./DarcsIO.lhs 164
 instance MonadPlus TolerantIO where
    mzero = TIO $ mzero
-   mplus (TIO a) (TIO b) = TIO $ mplus a b
+   mplus a b = TCatch a b
 
 instance ReadableDirectory TolerantIO where
     mDoesDirectoryExist d = TIO $ mDoesDirectoryExist d
hunk ./DarcsIO.lhs 170
     mDoesFileExist f = TIO $ mDoesFileExist f
     mIsFileExecutable f = TIO $ mIsFileExecutable f
-    mInCurrentDirectory i (TIO j) = TIO $ mInCurrentDirectory i j
+    mInCurrentDirectory i j =
+        TNested (\j' -> TIO $ mInCurrentDirectory i j') j
     mGetDirectoryContents = TIO mGetDirectoryContents
     mReadBinFile f = TIO $ mReadBinFile f
     mReadFilePS f = TIO $ mReadFilePS f
hunk ./DarcsIO.lhs 177
 
 instance WriteableDirectory TolerantIO where
-     mWithCurrentDirectory f (TIO m) = TIO $ mWithCurrentDirectory f m
+     mWithCurrentDirectory = mInCurrentDirectory
      mSetFileExecutable f e = warning $ mSetFileExecutable f e
      mWriteBinFile f s = warning $ mWriteBinFile f s
      mWriteFilePS f s = warning $ mWriteFilePS f s
hunk ./DarcsIO.lhs 201
         x = fn2fp a
         y = fn2fp b
         couldNotRename = "Could not rename " ++ x ++ " to " ++ y
-
-warning :: IO () -> TolerantIO ()
-warning io = TIO $ catch io $ \e -> putStrLn $ "Warning: " ++ prettyException e
 \end{code}
 \end{comment}
 
hunk ./DarcsRepo.lhs 267
           patches <- get_whole_repo_patches
           createDirectoryIfMissing True fp
           withCurrentDirectory fp $
-              apply_patches [] False noPut noPut patches
+              apply_patches [] noPut noPut patches
     where noPut _ = return ()
 
 createPartialsPristineDirectoryTree :: [FilePath] -> Pristine -> FilePath
hunk ./DarcsRepo.lhs 305
         Nothing -> do
            patches <- get_whole_repo_patches
            withDelayedDir "pristine.temp" $ \cd -> do
-               apply_patches [] False noPut noPut patches
+               apply_patches [] noPut noPut patches
                mmap_slurp cd
              where noPut _ = return ()
 
hunk ./DarcsRepo.lhs 570
     ps <- read_repo "."
     case get_patches_beyond_tag pinfo ps of
         [extras] -> withRecorded (withTempDir "checkpoint") $ \_ -> do
-                    apply_patches [] False noPut noPut $ map invert_it extras
+                    apply_patches [] noPut noPut $ map invert_it extras
                     job
         _ -> bug "with_tag"
     where noPut _ = return ()
hunk ./DarcsRepo.lhs 606
 
 \begin{code}
 apply_patches_with_feedback :: [DarcsFlag]
-                            -> Bool -- ^ is working dir; see 'apply'
                             ->(Int -> Int -> PatchInfo -> IO())
                             -> (Doc -> IO ())
                             -> [(PatchInfo, Maybe Patch)] -> IO ()
hunk ./DarcsRepo.lhs 609
-apply_patches_with_feedback  _ _ _ _ [] = return ()
-apply_patches_with_feedback opts isW feedback putInfo patches = do
+apply_patches_with_feedback _ _ _ [] = return ()
+apply_patches_with_feedback opts feedback putInfo patches = do
     apply_cautiously patches 1
     where patch_count = length patches
           apply_cautiously ((pinfo, Nothing) : _) _ =
hunk ./DarcsRepo.lhs 617
              do errorDoc $ text "Couldn't read patch" <+> human_friendly pinfo
           apply_cautiously ((pinfo, Just p) : more_patches) index =
              do feedback index patch_count pinfo
-                apply opts isW p `catch` \e ->
+                apply opts p `catch` \e ->
                   do putInfo $ text "Unapplicable patch:"
                      putInfo $ human_friendly pinfo
                      ioError e
hunk ./DarcsRepo.lhs 625
           apply_cautiously [] _ = return ()
 
 apply_patches :: [DarcsFlag]
-              -> Bool -- ^ is working dir; see 'apply'
               -> (Doc -> IO ()) -> (Doc -> IO ())
               -> [(PatchInfo, Maybe Patch)] -> IO ()
hunk ./DarcsRepo.lhs 627
-apply_patches opts isW putVerbose putInfo patches =
-    apply_patches_with_feedback opts isW normalFeedback putInfo patches
+apply_patches opts putVerbose putInfo patches =
+    apply_patches_with_feedback opts normalFeedback putInfo patches
     where normalFeedback _ _ pinfo = putVerbose $ text "Applying patch" <+> human_friendly pinfo  
 
 simple_feedback :: [DarcsFlag] -> Int -> Int -> PatchInfo -> IO ()
hunk ./Get.lhs 177
                    needed_patches = reverse $ concat $
                                     get_patches_beyond_tag pi_ch local_patches
                    in do write_checkpoint_patch p_ch
-                         apply opts False p_ch `catch`
+                         apply opts p_ch `catch`
                              \e -> fail ("Bad checkpoint!\n" ++ show e)
hunk ./Get.lhs 179
-                         apply_patches_with_feedback opts False
+                         apply_patches_with_feedback opts
                                   feedback putInfo needed_patches
hunk ./Get.lhs 181
-          else apply_patches_with_feedback opts False feedback putInfo
+          else apply_patches_with_feedback opts feedback putInfo
                    $ reverse $ concat local_patches
   putVerbose $ text "Writing the pristine"
   pristine <- identifyPristine
hunk ./Get.lhs 278
        pris <- identifyPristine
        applyPristine pris (invert $ join_patches ps) `catch` \e ->
            fail ("Unable to apply inverse patch!\n" ++ show e)
-       apply opts False (invert $ join_patches ps) `catch` \e ->
+       apply opts (invert $ join_patches ps) `catch` \e ->
            fail ("Couldn't undo patch in working dir.\n" ++ show e)
        sync_repo pris
                         
hunk ./Match.lhs 297
               | otherwise = apply_invp p >> apply_foo (ps:xs)
 
 apply_invp :: (PatchInfo, Maybe Patch) -> IO ()
-apply_invp p = apply [] False (invert $ fromJustP p) `catch` \e ->
+apply_invp p = apply [] (invert $ fromJustP p) `catch` \e ->
                    fail ("Inverse patch failed!\n" ++ show e)
     where fromJustP (_, Just pa) = pa
           fromJustP (pinf, Nothing) =
hunk ./Match.lhs 311
 get_dropn :: String -> Int -> IO ()
 get_dropn r n = do createRemotePristineDirectoryTree r
                    repo <- read_repo r
-                   apply_patches [] False silently silently $
+                   apply_patches [] silently silently $
                                  map invit $ safetake n $ concat repo
     where invit (pinf, Nothing) = (pinf, Nothing)
           invit (pinf, Just p) = (pinf, Just $ invert p)
hunk ./Match.lhs 328
     let pinfo = fromJust $ patch2patchinfo $ find_a_patch match ps
     case get_patches_beyond_tag pinfo ps of
         [extras] -> do createRemotePristineDirectoryTree r
-                       apply_patches [] False noPut noPut $ map invert_it extras
+                       apply_patches [] noPut noPut $ map invert_it extras
         _ -> impossible
     where noPut _ = return ()
           invert_it (pin, Just p) = (pin, Just $ invert p)
hunk ./PatchApply.lhs 94
 \section{Applying patches}
 
 \begin{code}
-apply_to_filepaths :: Bool -- ^ is working dir; see 'apply'
-                   -> Patch -> [FilePath] -> [FilePath]
-apply_to_filepaths isW pa fs = withFilePaths fs (apply [] isW pa)
+apply_to_filepaths :: Patch -> [FilePath] -> [FilePath]
+apply_to_filepaths pa fs = withFilePaths fs (apply [] pa)
 
 apply_to_slurpy :: Patch -> Slurpy -> Maybe Slurpy
hunk ./PatchApply.lhs 98
-apply_to_slurpy p s = case withSlurpy s (apply [] False p) of
+apply_to_slurpy p s = case withSlurpy s (apply [] p) of
                           Left _ -> Nothing
                           Right (s', ()) -> Just s'
 
hunk ./PatchApply.lhs 109
 \end{code}
 
 \begin{code}
-apply :: WriteableDirectory m
-      => [DarcsFlag]
-      -> Bool -- ^ working directory - if True, this means some inconsitencies such
-              --   as removing a non-empty directory are treated as warnings, not
-              --   errors.  When in doubt, set to False.
-      -> Patch -> m ()
+apply :: WriteableDirectory m => [DarcsFlag] -> Patch -> m ()
 
hunk ./PatchApply.lhs 111
-apply opts isW (NamedP _ _ p) = apply opts isW p
-apply opts isW p | is_merger p = apply opts isW (merger_equivalent p)
-apply _ _ (Merger _ _ _ _ _ _) = impossible
-apply opts isW (Conflictor False a [_]) = apply opts isW (invert $ join_patches a)
-apply opts isW (Conflictor True a [_]) = apply opts isW (join_patches a)
-apply _ _ (Conflictor _ _ _) = return ()
-apply opts isW (ComP ps) = apply_list opts isW ps
-apply opts isW (Split ps) = apply_list opts isW ps
+apply opts (NamedP _ _ p) = apply opts p
+apply opts p | is_merger p = apply opts (merger_equivalent p)
+apply _ (Merger _ _ _ _ _ _) = impossible
+apply opts (Conflictor False a [_]) = apply opts (invert $ join_patches a)
+apply opts (Conflictor True a [_]) = apply opts (join_patches a)
+apply _ (Conflictor _ _ _) = return ()
+apply opts (ComP ps) = apply_list opts ps
+apply opts (Split ps) = apply_list opts ps
 
hunk ./PatchApply.lhs 120
-apply _ _ (FP f RmFile) = mRemoveFile f
-apply _ _ (FP f AddFile) = mCreateFile f
-apply opts isW p@(FP _ (Hunk _ _ _)) = apply_list opts isW [p]
-apply _ _ (FP f (TokReplace t o n)) = mModifyFilePSs f doreplace
+apply _ (FP f RmFile) = mRemoveFile f
+apply _ (FP f AddFile) = mCreateFile f
+apply opts p@(FP _ (Hunk _ _ _)) = apply_list opts [p]
+apply _ (FP f (TokReplace t o n)) = mModifyFilePSs f doreplace
     where doreplace ls =
               case mapM (try_tok_internal t
                          (packString o) (packString n)) ls of
hunk ./PatchApply.lhs 130
               Nothing -> fail $ "replace patch to " ++ fn2fp f
                          ++ " couldn't apply."
               Just ls' -> return $ map concatPS ls'
-apply _ _ (FP f (Binary o n)) = mModifyFilePS f doapply
+apply _ (FP f (Binary o n)) = mModifyFilePS f doapply
     where doapply oldf = if o == oldf
                          then return n
                          else fail $ "binary patch to " ++ fn2fp f
hunk ./PatchApply.lhs 135
                                   ++ " couldn't apply."
-apply _ _ (DP d AddDir) = mCreateDirectory d
-apply _ _ (DP d RmDir) = mRemoveDirectory d
+apply _ (DP d AddDir) = mCreateDirectory d
+apply _ (DP d RmDir) = mRemoveDirectory d
 
hunk ./PatchApply.lhs 138
-apply _ _ (Move f f') = mRename f f'
-apply _ _ (ChangePref p f t) =
+apply _ (Move f f') = mRename f f'
+apply _ (ChangePref p f t) =
  do b <- mDoesDirectoryExist (fp2fn "_darcs/prefs")
     when b $ change_prefval p f t
 
hunk ./PatchApply.lhs 143
-apply_list :: WriteableDirectory m => [DarcsFlag] -> Bool -> [Patch] -> m ()
-apply_list _ _ [] = return ()
-apply_list opts isW ((FP f h@(Hunk _ _ _)):the_ps)
+apply_list :: WriteableDirectory m => [DarcsFlag] -> [Patch] -> m ()
+apply_list _ [] = return ()
+apply_list opts ((FP f h@(Hunk _ _ _)):the_ps)
  = case span f_hunk the_ps of
        (xs, ps') ->
            do let foo = h:map (\(FP _ h') -> h') xs
hunk ./PatchApply.lhs 155
                                    SetScriptsExecutable `elem` opts
                                  -> mSetFileExecutable f True
                 _ -> return ()
-              apply_list opts isW ps'
+              apply_list opts ps'
     where f_hunk (FP f' (Hunk _ _ _)) | f == f' = True
           f_hunk _ = False
           hunkmod [] ps = return ps
hunk ./PatchApply.lhs 165
                  Just (_, Nothing) -> impossible
                  Nothing -> fail $ "Error applying hunk to file " ++ fn2fp f
           hunkmod _ _ = impossible
-apply_list opts isW (p:ps) = do apply opts isW p
-                                apply_list opts isW ps
+apply_list opts (p:ps) = do apply opts p
+                            apply_list opts ps
 \end{code}
 
 \subsection{Hunk patches}
hunk ./Pristine.lhs 136
 -- We don't need flags for now, since we don't care about
 -- SetScriptsExecutable for the pristine cache.
 applyPristine (PlainPristine n) p =
-    mWithCurrentDirectory (fp2fn n) $ apply [] False p
+    mWithCurrentDirectory (fp2fn n) $ apply [] p
 applyPristine (HashedPristine _) _ =
     fail "HashedPristine is not implemented yet."
 
hunk ./Repair.lhs 94
             case patch2patchinfo chk of
             Just chtg -> do
                 putVerbose $ text "I am repairing from a checkpoint."
-                apply_patches_with_feedback [] False feedback putInfo $
+                apply_patches_with_feedback [] feedback putInfo $
                                                 (chtg, Just chk)
                     : reverse (concat $ get_patches_beyond_tag chtg patches)
             Nothing -> impossible -- checkpoint is always a tag
hunk ./Repair.lhs 98
-        Nothing -> apply_patches_with_feedback [] False feedback putInfo
+        Nothing -> apply_patches_with_feedback [] feedback putInfo
                    $ reverse $ concat patches
     -- withTempDir ignores error on delete -- hence the hack below.
     setCurrentDirectory formerdir
hunk ./Repository.lhs 49
 import qualified DarcsRepo
 import qualified GitRepo
 import DarcsFlags ( DarcsFlag(AnyOrder, Boring, LookForAdds, Verbose,
+                              Quiet,
                               WorkDir, UMask) )
 import PatchInfo ( PatchInfo )
 import Patch ( Patch, flatten, join_patches, reorder_and_coalesce,
hunk ./Repository.lhs 64
 #ifdef HAVEWX
 import Lock ( takeLock, releaseLock, withLockCanFail )
 #endif
-import DarcsIO ( runTolerantly )
+import DarcsIO ( runTolerantly, runSilently )
 #include "impossible.h"
 
 data Repository = Repo !String !RepoFormat !RepoType
hunk ./Repository.lhs 244
 
 applyToWorking :: Repository -> [DarcsFlag] -> Patch -> IO ()
 applyToWorking (Repo r _ (DarcsRepository _)) opts patch =
-    withCurrentDirectory r $ runTolerantly $ apply opts True patch
+    withCurrentDirectory r $ run $ apply opts patch
+        where run = if Quiet `elem` opts then runSilently
+                                         else runTolerantly
 applyToWorking (Repo _ _ GitRepository) _ _ = return ()
 
 
hunk ./Resolution.lhs 161
    setCurrentDirectory former_dir
    withTempDir "ancestor" $ \da -> do
      cloneTree d1 "."
-     apply [] False (invert p1)
+     apply [] (invert p1)
      setCurrentDirectory former_dir
      withTempDir "cleanmerged" $ \dc -> do
        cloneTree d1 "."
hunk ./Resolution.lhs 165
-       apply [] False pmerged
+       apply [] pmerged
        setCurrentDirectory former_dir
        withTempDir "merged" $ \dm -> do
          cloneTree dc "."
hunk ./Resolution.lhs 172
          setCurrentDirectory former_dir
          withTempDir "version2" $ \d2 -> do
            cloneTree da "."
-           apply [] False p2
+           apply [] p2
            let nms = list_conflicted_files pmerged
hunk ./Resolution.lhs 174
-               nas = apply_to_filepaths False (invert pmerged) nms
-               n1s = apply_to_filepaths False p1 nas
-               n2s = apply_to_filepaths False p2 nas
+               nas = apply_to_filepaths (invert pmerged) nms
+               n1s = apply_to_filepaths p1 nas
+               n2s = apply_to_filepaths p2 nas
                ns = zip4 nas n1s n2s nms
              in do
              mapM_ (externally_resolve_file c da d1 d2 dm) ns
hunk ./Revert.lhs 98
   case maybe_changes of
     Nothing -> putStrLn "There are no changes to revert!"
     Just changes ->
-      let pre_changed_files = apply_to_filepaths True (invert changes) files in
+      let pre_changed_files = apply_to_filepaths (invert changes) files in
       if is_null_patch $ choose_touching pre_changed_files changes
       then putStrLn "There are no changes to revert!"
       else with_selected_last_changes_to_files "revert" opts working_dir
hunk ./Test.lhs 93
     Just _ -> do
       formerdir <- getCurrentDirectory
       withRecorded (wd "testing") $ \td -> do
-        apply opts False p
+        apply opts p
         setCurrentDirectory formerdir
         ec <- run_test opts td
         if ec == ExitSuccess
hunk ./TouchesFiles.lhs 84
           affects t f = case splitAt (length f) t of
                         (t', '/':_) -> t' == f
                         _ -> False
-          fs' = sort $ apply_to_filepaths False p fs
+          fs' = sort $ apply_to_filepaths p fs
 \end{code}
hunk ./TrackDown.lhs 98
     test_result <- test
     if test_result == ExitSuccess
        then putStrLn "Success!"
-       else do apply opts False p `catch` \e -> fail ("Bad patch:\n" ++ show e)
+       else do apply opts p `catch` \e -> fail ("Bad patch:\n" ++ show e)
                putStrLn "Trying without the patch:"
                putDocLn $ human_friendly $
                         fromJust $ patch2patchinfo $ invert p
hunk ./WhatsNew.lhs 115
     ftf <- filetype_function
     let chold = case maybe_old_changes of Nothing -> null_patch
                                           Just p -> p
-        pre_changed_files = apply_to_filepaths False (invert chold) files
+        pre_changed_files = apply_to_filepaths (invert chold) files
         select_adds = join_patches . filter (not . is_hunk) . flatten
         select_files = choose_touching pre_changed_files
         cho = select_files chold
hunk ./WhatsNew.lhs 147
       Nothing -> do putStrLn "No changes!"
                     exitWith $ ExitFailure 1
       Just changes ->
-          let pre_changed_files = apply_to_filepaths False (invert changes) files
+          let pre_changed_files = apply_to_filepaths (invert changes) files
               ch =  choose_touching pre_changed_files changes
                     in
               if is_null_patch ch
}

Context:

[Use LaTeX for ISO 8601 hyperlink.
Eric Kow <[EMAIL PROTECTED]>**20070217071601] 
[Documentation only: add link for ISO 8601 format
Kirsten Chevalier <[EMAIL PROTECTED]>**20070216004007
 
 In the documentation, make "ISO 8601 format" a link to the official
 W3C page describing the format (for those who don't know it by heart).
] 
[fix bugs in replace.sh script--running wrong darcs.
David Roundy <[EMAIL PROTECTED]>**20070128001826] 
[add documentation for DARCS_PAGER
Benedikt Schmidt <[EMAIL PROTECTED]>**20070126142649] 
[Fix issue383 - allow --disable-ssh-cm for 'darcs changes'.
Georg Neis <[EMAIL PROTECTED]>**20070121224417] 
[Canonize Marco Túlio Gontijo e Silva.
Eric Kow <[EMAIL PROTECTED]>**20070113231736
 
 Sorry for stripping off the accent.
 
] 
[Redundant noncomments
[EMAIL PROTECTED]
 
 noncomments was already called by get_preffile via get_lines.
] 
[Fix issue376 - inconsistent punctuation in darcs get.
Eric Kow <[EMAIL PROTECTED]>**20061231180024
 
] 
[Fix issue367 - pull help message.
Eric Kow <[EMAIL PROTECTED]>**20061231174322] 
[fix some changelog entries
Tommy Pettersson <[EMAIL PROTECTED]>**20061231210024] 
[allow commented tests in tests_to_run.
David Roundy <[EMAIL PROTECTED]>**20061211000322] 
[use variable TEST_FILTER_FILE in makefile.
David Roundy <[EMAIL PROTECTED]>**20061204151217] 
[add test target for testing hashed inventories.
David Roundy <[EMAIL PROTECTED]>**20060927020127] 
[update web page for new mailing list server.
David Roundy <[EMAIL PROTECTED]>**20070116162930] 
[fix spelling errors in comments
Benedikt Schmidt <[EMAIL PROTECTED]>**20061222020037] 
[Fix ssh.sh test.
Dave Love <[EMAIL PROTECTED]>**20061218223442] 
[add warning about ALL and obliterate --all to documentation
Tommy Pettersson <[EMAIL PROTECTED]>**20061219180302] 
[Fix includes in External.hs.
Dave Love <[EMAIL PROTECTED]>**20061218224158
 You can't put comments before {-# INCLUDE ...
] 
[add test for reverting removed directory
Tommy Pettersson <[EMAIL PROTECTED]>**20061108202344] 
[Improve error messages in push_cmd
[EMAIL PROTECTED]
 
 I ran into this because MSYS was munging my repository directory in a
 horrible way. This resulted in a bad repo directory getting passed into
 darcs, which resulted in a fromJust error, which we all know makes the
 baby Jesus cry. So, I at least refactored the code to give a better
 error message, though there may well be a better solution.
] 
[Implement prettyException.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061218025440] 
[Simplify common libcurl errors.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061218025419] 
[fix issue369 by failing if quickcheck isn't available
David Roundy <[EMAIL PROTECTED]>**20061218021545] 
[Don't QP-encode bundles when pushing locally.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061218002533] 
[Make darcs push QP-encode the bundle before transferring.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061217234635
 This should hopefully fix issues with scp/sftp corrupting bundles in transit.
] 
[Adapt callers to new calling convention for make_email.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061217234608
 Use Just at the right places.
] 
[Make arguments to make_email optional.
Juliusz Chroboczek <[EMAIL PROTECTED]>**20061217234501
 Makes contents and filename optional.  If they are omitted, we still
 generate a conforming MIME message.
] 
[add test for get --tag and pending
Tommy Pettersson <[EMAIL PROTECTED]>**20061211192821] 
[add new test related to issue262.
David Roundy <[EMAIL PROTECTED]>**20061217221041
 This issue seems to already have been fixed.
] 
[Added test for reverting an unrecorded add
[EMAIL PROTECTED] 
[add test that sigPIPE doesn't make darcs fail.
David Roundy <[EMAIL PROTECTED]>**20061209230155] 
[make it an error to "put" into a preexisting directory.
David Roundy <[EMAIL PROTECTED]>**20061203205826
 This changes darcs' behavior I believe for the better.  Often one could be
 tempted to try to put into a directory, expecting to have the repository
 created as a subdirectory there, and it seems confusing (confused me) to
 have instead the repository contents mingled with whatever was already in
 that directory.  Put should behave like get in this regard, in that it
 shouldn't mix the new repo with a preexisting directory.
] 
[adapt test sametwice to new obliterate --all feature
Tommy Pettersson <[EMAIL PROTECTED]>**20061130132058] 
[Adapt test perms.sh to obliterate --all feature.
Eric Kow <[EMAIL PROTECTED]>**20061209200625] 
[use impossible to document impossible case in Repair.
David Roundy <[EMAIL PROTECTED]>**20061204152854] 
[fix for Issue111, obliterate --all
David Roundy <[EMAIL PROTECTED]>**20061129164016
 This is a patch to implement the wishless item Issue111,
 which asks for an --all option to obliterate.  The idea is
 that you might use the --patches flag to select a bunch of
 patches and not want to have to say yess to all of them.
 
 For good measure, I also added it to unpull and unrecord.
] 
[catch exceptions in stdout_is_a_pipe
Simon Marlow <[EMAIL PROTECTED]>**20061129160620] 
[hFlush after "waiting for lock" message
Simon Marlow <[EMAIL PROTECTED]>**20061129160342
 On Windows, stdout isn't always in line-buffered mode, but we really
 want to see the message about waiting for a lock quickly.  Mostly
 because ^C isn't always caught properly on Windows and lock files are
 often left behind, but that's another storey...
 
] 
[add explicit import list
Simon Marlow <[EMAIL PROTECTED]>**20061129160144] 
[ignore failure from hSetBuffering
Tommy Pettersson <[EMAIL PROTECTED]>**20061117221424
 This affects:
   issue41	Doesn't like pasted text.
   issue94	Crash on bogus input
   issue146	hSetBuffering: invalid argument
   issue318	buffering error of darcs record under bash/cmd.exe
 It doesn't necessarily "fix" anything. It prevents darcs from quiting,
 instead continuing with perhaps an undesirable buffering mode, which may or
 may not be better ... or worse.
] 
[Hard link support on Windows
Simon Marlow <[EMAIL PROTECTED]>*-20061204162040
 This works only on NTFS filesystems.  Also it requires Windows 2000 or
 later; this may or may not be acceptable, I'll leave that up to the
 darcs maintainers to decide.
] 
[Hard link support on Windows
Simon Marlow <[EMAIL PROTECTED]>**20061204162040
 This works only on NTFS filesystems.  Also it requires Windows 2000 or
 later; this may or may not be acceptable, I'll leave that up to the
 darcs maintainers to decide.
] 
[Canonize Kirsten Chevalier.
Kirsten Chevalier <[EMAIL PROTECTED]>**20061217025004
 
 Added my name to the list of authors who originally only submitted an email
 address.
 
] 
[Documentation only - clarify meaning of --from and --author
Kirsten Chevalier <[EMAIL PROTECTED]>**20061217024927
   
 Clarified the meaning of --from and --author. I had assumed that these
 options also set the From: address on the email sent by "darcs sent".  Of
 course they don't, but it's better to make this clear.
 
] 
[Do _not_ allow escaped quotes in `quoted'.
Eric Kow <[EMAIL PROTECTED]>**20061030064531
 
 This undoes the patch by Dave Love: Allow escaped quotes in `quoted'.
 The immediate problem is that it breaks make_changelog (because one of
 Tommy's entries matches on a backslash).  This feature might need more
 discussion before we include it (or not).
 
] 
[Replace tabs with spaces (escaped quotes in PatchMatch).
Eric Kow <[EMAIL PROTECTED]>**20061023192003] 
[Allow escaped quotes in `quoted'.
Dave Love <[EMAIL PROTECTED]>**20060716193940] 
[Rename ssh_test to ssh.sh (for shell harness).
Eric Kow <[EMAIL PROTECTED]>**20061121141101
 
 Note that you must set environment variables for it do anything
 useful (namely [EMAIL PROTECTED]); something like the following
 should work:
   [EMAIL PROTECTED] make test
 
 You need to be using public key authentication to have a fully
 automated test.
 
] 
[Overhaul and improve automation of ssh_test.
Eric Kow <[EMAIL PROTECTED]>**20061121141802
 
 * Now quits if you don't supply REMOTE; does not have any
   silly default values
 * Options now passed in through environment variables, so:
     NO_CONTROL_MASTER=1 [EMAIL PROTECTED] ./ssh_test
 * Performs some automated success checks (which means that
   it should be possible to use this from the harness if you
   have ssh-agent running)
 * Performs darcs send test
 * Does not try to pass darcs-ssh flags (like --disable-ssh-cm)
   to non-ssh-using commands like record
 
] 
[Add a semi-automated test for SSH-related things.
Eric Kow <[EMAIL PROTECTED]>**20061110110801
 
 Testing SSH stuff is tricky in that (1) you need some place to connect
 to and (2) you often want to make sure that the user interactions work
 out right.  But it can't hurt to script away the boring stuff so that
 you are naturally encouraged to test things out more thoroughly.
] 
[Remove raw_mode functions from atomic_create.h.
Eric Kow <[EMAIL PROTECTED]>**20061008202738
 
 It seems these were once implemented in compat.c and have since been
 reimplemented in Haskell by Ian Lynagh on 2005-07-30.  These appear to
 just be leftover declarations in the C header.
 
] 
[Add make rules for tags files.
Dave Love <[EMAIL PROTECTED]>**20061113213923] 
[configure should fail if a required module isn't present.
David Roundy <[EMAIL PROTECTED]>**20061128024557] 
[look for --disable-ssh-cm in defaults files (issue351)
Tommy Pettersson <[EMAIL PROTECTED]>**20061117180942] 
[Define infodepspatch locally in AmendRecord instead of exporting it from Patch
[EMAIL PROTECTED]
 
] 
[Amending a patch doesn't remove explicit dependencies
[EMAIL PROTECTED] 
[Make libcurl use any http authentication.
Tobias Gruetzmacher <[EMAIL PROTECTED]>**20061118230406
 This let darcs use repositories protected with digest authentication.
] 
[Support darcs send --disable-ssh-cm.
Eric Kow <[EMAIL PROTECTED]>**20061121134158] 
[Redirect stderr to Null when exiting SSH control master.
Eric Kow <[EMAIL PROTECTED]>**20061118212115
 
 This suppresses the output
 * Pseudo-terminal will not be allocated because stdin is not a terminal.
   (result of redirecting stdin from /dev/null)
 * Exit request sent.
   (seems to be normal output. Seems also that there is no way to suppress
    this; -q does not do the job, for example)
 
] 
[Fix curses stuff, especially on Solaris 10.
Dave Love <[EMAIL PROTECTED]>**20061120171211] 
[Canonize Edwin Thomson.
Eric Kow <[EMAIL PROTECTED]>**20061118174454] 
[Annotate various boring patterns.
Dave Love <[EMAIL PROTECTED]>**20061113225701] 
[remove link to obsolete mirror of kernel repo.
David Roundy <[EMAIL PROTECTED]>**20061212012644] 
[TAG 1.0.9rc2
Tommy Pettersson <[EMAIL PROTECTED]>**20061116140351] 
Patch bundle hash:
8892a2a52408e6934ace1daa59423f6404630d98
_______________________________________________
darcs-devel mailing list
[email protected]
http://lists.osuosl.org/mailman/listinfo/darcs-devel

Reply via email to