stack-1.1.0: The Haskell Tool Stack

Safe HaskellNone



Create new a new project directory populated with a basic working project.



new :: (HasConfig r, MonadReader r m, MonadLogger m, MonadCatch m, MonadThrow m, MonadIO m, HasHttpManager r, Functor m, Applicative m) => NewOpts -> Bool -> m (Path Abs Dir) Source

Create a new project with the given options.

data NewOpts Source

Options for creating a new project.




newOptsProjectName :: PackageName

Name of the project to create.

newOptsCreateBare :: Bool

Whether to create the project without a directory.

newOptsTemplate :: Maybe TemplateName

Name of the template to use.

newOptsNonceParams :: Map Text Text

Nonce parameters specified just for this invocation.

defaultTemplateName :: TemplateName Source

The default template name you can use if you don't have one.

templateNameArgument :: Mod ArgumentFields TemplateName -> Parser TemplateName Source

An argument which accepts a template name of the format foo.hsfiles or foo, ultimately normalized to foo.

getTemplates :: (MonadIO m, MonadThrow m, MonadReader r m, HasHttpManager r, MonadCatch m) => m (Set TemplateName) Source

Get the set of templates.

listTemplates :: (MonadIO m, MonadThrow m, MonadReader r m, HasHttpManager r, MonadCatch m, MonadLogger m) => m () Source

Display the set of templates accompanied with description if available.