Skip to content

FileStdout should probably not erase the content of the file on exit failure #854

Description

@kephas

If I use the action cmd_ Shell (FileStdout "foo.txt") "make-foo -" and the action fails, for example because make-foo is not in the $PATH, then shake will erase the content of foo.txt if it exists. I would expect that it is never the expected behaviour.

This could be solved either by a warning in the docs and possibly an alternate option like FileStdoutSuccess or a function writeStdout :: FilePath -> Action (Exit, Stdout String) -> Action (), or by changing the behaviour of FileStdout.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions