Skip to content

Commit 75abe90

Browse files
committed
fix --fit for Windows
1 parent 60b34b5 commit 75abe90

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tools/nimgrep.nim

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1168,6 +1168,8 @@ for kind, key, val in getopt():
11681168
of "fit":
11691169
incl(options, optFit)
11701170
limitChar = terminalWidth()
1171+
when defined(windows): # Windows cmd&powershell add an empty line when
1172+
limitChar -= 1 # printing '\n' right after the last column
11711173
of "onlyascii", "only-ascii", "o": optOnlyAscii = true
11721174
of "verbose": incl(options, optVerbose)
11731175
of "filenames": incl(options, optFilenames)

0 commit comments

Comments
 (0)