hscaffold-0.4.5.0: Very simple file/directory structure scaffolding writer monad EDSL

Safe HaskellSafe
LanguageHaskell2010

Hscaffold.EDSL

Synopsis

Documentation

directory :: MonadWriter (ScaffoldAction e) m => FilePath -> WriterT (ScaffoldAction e) m b -> m b Source #

Create a directory with the nested contents

directoryWith :: MonadWriter (ScaffoldAction e) m => Permissions -> FilePath -> WriterT (ScaffoldAction e) m b -> m b Source #

Create a directory with the nested contents and permissions

file :: MonadWriter (ScaffoldAction e) m => FilePath -> Text -> m () Source #

Create a file with the given contents

fileWith :: MonadWriter (ScaffoldAction e) m => Permissions -> FilePath -> Text -> m () Source #

Create a file with the given contents and permissions

permissions :: MonadWriter (ScaffoldAction e) m => FilePath -> Permissions -> m () Source #

Set permissions on a filepath

link :: MonadWriter (ScaffoldAction e) m => FilePath -> FilePath -> m () Source #

Create a symbolic link between two filepaths

touch :: MonadWriter (ScaffoldAction e) m => FilePath -> m () Source #

Write the empty string to a file

touchWith :: MonadWriter (ScaffoldAction e) m => Permissions -> FilePath -> m () Source #

Write the empty string to a file with given permissions

copy :: MonadWriter (ScaffoldAction e) m => FilePath -> FilePath -> m () Source #

Copy a file from A to B

Non-absolute paths are treated relative to the *current* root, nested blocks change the root

copyWith :: MonadWriter (ScaffoldAction e) m => Permissions -> FilePath -> FilePath -> m () Source #

Copy a file from A to B and set permissions on B, see copy