Re: [Haskell-cafe] ANN: cautious-file 0.1.1: Ways to write a file cautiously, to avoid data loss

2009-07-20 Thread Robin Green
I've since uploaded two new versions with the following changes: 0.1.2: Fixed an issue where it would clobber symbolic links to files, which is usually not what you want. Test case added for this. 0.1.3: ByteString support! FFI is also now used under the hood to do things in a slightly less

Re: [Haskell-cafe] ANN: cautious-file 0.1.1: Ways to write a file cautiously, to avoid data loss

2009-07-20 Thread Felipe Lessa
Nice library! On Sun, Jul 19, 2009 at 11:35:34PM +0100, Robin Green wrote: A variant, writeFileWithBackup, also allows you to supply a custom backup computation to backup old copy(ies) of the destination file It would be nice to have the backup action receive the file name as a parameter, so

[Haskell-cafe] ANN: cautious-file 0.1.1: Ways to write a file cautiously, to avoid data loss

2009-07-19 Thread Robin Green
I'm pleased to announce the first public release of cautious-file: http://hackage.haskell.org/package/cautious-file This library currently provides a writeFile function that is intended to have three advantages over Prelude.writeFile: 1. There was a controversy a few months ago about the new