all repos — minline @ d49c4284181f9eee642b91d98a40958a388dc71a

A minimalist but highly-customizable line editing library.

Prevents ansi reset code output on exit when not an interactable terminal
inivekin inivekin
Fri, 16 Jun 2023 06:33:05 +0800
commit

d49c4284181f9eee642b91d98a40958a388dc71a

parent

73012b2d9fc7809a4f48a9733c929d0a969a9c8b

1 files changed, 2 insertions(+), 1 deletions(-)

jump to
M nimline.nimnimline.nim

@@ -37,7 +37,8 @@ strutils,

std/exitprocs, os -addExitProc(resetAttributes) +if isatty(stdin): + addExitProc(resetAttributes) when defined(windows): proc putchr*(c: cint): cint {.discardable, header: "<conio.h>", importc: "_putch".}