A cross-platform, cross-console way to handle echoing terminal input

Version on this page:0.1.3@rev:1
LTS Haskell 21.13:0.1.4
Stackage Nightly 2023-09-27:0.1.4
Latest on Hackage:0.1.4

See all snapshots echo appears in

BSD-3-Clause licensed by Ryan Scott
Maintained by Ryan Scott
This version can be pinned in stack with:echo-0.1.3@sha256:5490be9cfbea95e14a7a68b7d055ae8d295822e0b146d2ac8285b3e5a3e3282f,2500

Module documentation for 0.1.3

Depends on 3 packages(full list with versions):
Used by 2 packages in lts-11.22(full list with versions):


Hackage Hackage Dependencies Haskell Programming Language BSD3 License Build Windows build

The base library exposes the hGetEcho and hSetEcho functions for querying and setting echo status, but unfortunately, neither function works with MinTTY consoles on Windows. This is a serious issue, since hGetEcho and hSetEcho are often used to disable input echoing when a program prompts for a password, so many programs will reveal your password as you type it on MinTTY!

This library provides an alternative interface which works with both MinTTY and other consoles. An example is included which demonstrates how one might prompt for a password using this library. To build it, make sure to configure with the -fexample flag.


0.1.3 [2017-01-30]

  • The MinTTY-detection portion of this library has been split off into mintty, on which echo now depends.

0.1.2 [2017-01-09]

  • Use more efficient implementation for bracketInputEcho.

0.1.1 [2017-01-07]

  • Use System.Win32.MinTTY from Win32-2.5 or later if possible.

0.1 [2016-12-22]

  • First version.