packages feed

turtle 1.5.8 → 1.5.9

raw patch · 3 files changed

+19/−2 lines, 3 filesdep ~doctest

Dependency ranges changed: doctest

Files

CHANGELOG.md view
@@ -1,3 +1,7 @@+1.5.9++* Add `symlink`+ 1.5.8  * Bug fix: `invert` no longer rejects inputs where a prefix matches the inverted
src/Turtle/Prelude.hs view
@@ -127,6 +127,9 @@     , mktree     , cp     , cptree+#if !defined(mingw32_HOST_OS)+    , symlink+#endif     , rm     , rmdir     , rmtree@@ -348,12 +351,13 @@     readDirStream,     closeDirStream,     touchFile )+import System.Posix.Files (createSymbolicLink)       #endif import Prelude hiding (FilePath)  import Turtle.Pattern (Pattern, anyChar, chars, match, selfless, sepBy) import Turtle.Shell-import Turtle.Format (Format, format, makeFormat, d, w, (%))+import Turtle.Format (Format, format, makeFormat, d, w, (%), fp) import Turtle.Internal (ignoreSIGPIPE) import Turtle.Line @@ -1081,6 +1085,15 @@ -- | Copy a file cp :: MonadIO io => FilePath -> FilePath -> io () cp oldPath newPath = liftIO (Filesystem.copyFile oldPath newPath)++#if !defined(mingw32_HOST_OS)+-- | Create a symlink from one @FilePath@ to another+symlink :: MonadIO io => FilePath -> FilePath -> io ()+symlink a b = liftIO $ createSymbolicLink (fp2fp a) (fp2fp b)+  where+    fp2fp = unpack . format fp +  +#endif  -- | Copy a directory tree cptree :: MonadIO io => FilePath -> FilePath -> io ()
turtle.cabal view
@@ -1,5 +1,5 @@ Name: turtle-Version: 1.5.8+Version: 1.5.9 Cabal-Version: >=1.10 Build-Type: Simple License: BSD3