Skip to content

Commit

Permalink
Respect terminal width printing error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
edolstra committed Jun 15, 2020
1 parent f20bb98 commit 8b09981
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libutil/error.cc
Expand Up @@ -105,7 +105,7 @@ void printCodeLines(std::ostream &out, const string &prefix, const NixCode &nixC

std::ostream& operator<<(std::ostream &out, const ErrorInfo &einfo)
{
size_t errwidth = 80;
auto errwidth = std::max<size_t>(getWindowSize().second, 20);
string prefix = "";

string levelString;
Expand Down

0 comments on commit 8b09981

Please sign in to comment.