@@ -791,12 +791,13 @@ Command line equivalent (takes precedence): `--[no-]dump-logs` flag
791791
792792In the case of *non-interleaved* output and *more than one* target package,
793793Stack sends the build output from GHC for each target package to a log file,
794- unless an error occurs. For further information, see the
795- [`stack build --[no-]interleaved-output` flag](build_command.md#the-stack-build-- -no-interleaved-output-flag)
794+ unless an error occurs that prevents that . For further information, see the
795+ [`stack build --[no-]interleaved-output` flag](build_command.md#-no-interleaved-output-flag)
796796documentation.
797797
798798The value of the `dump-logs` key controls what, if any, log file content is sent
799- ('dumped') to the console at the end of the build. Possible values are :
799+ ('dumped') to the standard error output stream of the console at the end of the
800+ build. Possible values are :
800801
801802~~~yaml
802803dump-logs : none # don't dump the content of any log files
@@ -807,6 +808,15 @@ dump-logs: all # dump all of the content of log files
807808At the command line, `--no-dump-logs` is equivalent to `dump-logs : none` and
808809`--dump-logs` is equivalent to `dump-logs : all`.
809810
811+ If GHC reports an error during the build and a log file is created, that build
812+ output will be included in the log file. Stack will also report errors during
813+ building to the standard error output stream. That stream can be piped to a
814+ file. For example, for a file named `stderr.log` :
815+
816+ ~~~text
817+ stack --no-dump-logs --color always build --no-interleaved-output 2> stderr.log
818+ ~~~
819+
810820### extra-include-dirs
811821
812822Default: ` [] `
0 commit comments