packages feed

shake-plus 0.1.4.1 → 0.1.5.0

raw patch · 3 files changed

+20/−2 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Development.Shake.Plus.Directory: getDirectoryFilesWithinIO :: MonadIO m => Within b [FilePattern] -> m (Within b [Path Rel File])
+ Development.Shake.Plus.Directory: getDirectoryFilesWithinIO' :: MonadIO m => Within b [FilePattern] -> m [Within b (Path Rel File)]

Files

ChangeLog.md view
@@ -1,5 +1,9 @@ # Changelog for shake-plus +## v0.1.5.0++* Add `getDirectoryFilesWithinIO` and `getDirectoryFilesWithinIO'`+ ## v0.1.4.0  * Re-export `Development.Shake.shakeArgs`.
shake-plus.cabal view
@@ -4,10 +4,10 @@ -- -- see: https://github.com/sol/hpack ----- hash: e59d9e313ffd79385a1e9add5230b0f6fc1f63b4f2bf492273fa1bb08de94b1d+-- hash: 6699df4e285e18169a0f843645c0ab9d915cec197ed7dcaa40b4785e6a8fdd3c  name:           shake-plus-version:        0.1.4.1+version:        0.1.5.0 synopsis:       Re-export of Shake using well-typed paths and ReaderT. description:    Re-export of Shake using well-typed paths and ReaderT. You can thread logging through your Shake Actions, and better keep track of source and output folders using the Within type. category:       development, shake
src/Development/Shake/Plus/Directory.hs view
@@ -6,6 +6,8 @@ , getDirectoryFilesWithin' , getDirectoryDirs , getDirectoryFilesIO+, getDirectoryFilesWithinIO+, getDirectoryFilesWithinIO' ) where  import           Control.Comonad.Env as E@@ -46,3 +48,15 @@ -- | Lifted version of `Development.Shake.getDirectoryFilesIO` using well-typed `Path`s. getDirectoryFilesIO :: MonadIO m => Path b Dir -> [FilePattern] -> m [Path Rel File] getDirectoryFilesIO x y = liftIO $ traverse (liftIO . parseRelFile) =<< Development.Shake.getDirectoryFilesIO (toFilePath x) y++-- | Like `getDirectoryFilesIO`, but accepts a `Within` value and returns a `Within` contaning a list of `Path`s+getDirectoryFilesWithinIO :: MonadIO m => Within b [FilePattern] -> m (Within b [Path Rel File])+getDirectoryFilesWithinIO x = do+  xs <- getDirectoryFilesIO (E.ask x) (extract x)+  return (xs <$ x)++-- | Like `getDirectoryFilesWithinIO`, but returns a list of `Within` values instead of a `Within`` of a list.+getDirectoryFilesWithinIO' :: MonadIO m => Within b [FilePattern] -> m [Within b (Path Rel File)]+getDirectoryFilesWithinIO' x = do+  xs <- getDirectoryFilesIO (E.ask x) (extract x)+  return ((<$ x) <$> xs)