Skip to content

Commit

Permalink
Merge pull request #5523 from wraithm/master
Browse files Browse the repository at this point in the history
Remove indentation for error output
  • Loading branch information
snoyberg authored Apr 15, 2021
2 parents 255cd83 + b3eed4c commit 49515cb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ Other enhancements:
* Added `--candidate` flag to `upload` command to upload a package candidate
rather than publishing the package.

* Error output using `--no-interleaved-output` no longer prepends indentating
whitespace. This allows emacs compilation-mode and vim quickfix to locate
and track errors. See
[#5523](https://github.com/commercialhaskell/stack/pull/5523)

Bug fixes:

* `stack new` now suppports branches other than `master` as default for
Expand Down
4 changes: 2 additions & 2 deletions src/Stack/Types/Build.hs
Original file line number Diff line number Diff line change
Expand Up @@ -356,9 +356,9 @@ showBuildError isBuildingSetup exitCode mtaskProvides execName fullArgs logFiles
logLocations ++
(if null bss
then ""
else "\n\n" ++ doubleIndent (map T.unpack bss))
else "\n\n" ++ removeTrailingSpaces (map T.unpack bss))
where
doubleIndent = dropWhileEnd isSpace . unlines . fmap (\line -> " " ++ line)
removeTrailingSpaces = dropWhileEnd isSpace . unlines
dropQuotes = filter ('\"' /=)

instance Exception StackBuildException
Expand Down

0 comments on commit 49515cb

Please sign in to comment.