Skip to content

Support multiline script interpreter directive for better readability #1394

Closed
@harendra-kumar

Description

@harendra-kumar

When we have many packages to be specified on the embedded stack command the comment line can become too long. It would be nice to support a multiline comment so that it can formatted for better readability. Like this:

{- stack --verbosity silent 
         --resolver lts-3.14 
         --install-ghc runghc 
         --package system-filepath 
         --package system-argv0 
         --package random 
         --package argparser
         ...
-}

Further comments from the stack mailing list:

Perhaps {-# OPTIONS_STACK ... #-} would be a more standard syntax for it?

I'd worry about that being confused with compiler pragmas, and people expecting to to be used in all cases (i.e. by stack build as well). Since this only applies when using stack as a script interpreter, that would be misleading.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions