Cargo Features

[dependencies]
crossterm = { version = "0.28.1", default-features = false, features = ["windows", "bracketed-paste", "event-stream", "use-dev-tty", "events", "serde", "libc"] }

Features

default = bracketed-paste, events, windows

These default features are set whenever crossterm is added without default-features = false somewhere in the dependency tree.

windows default

Disables winapi dependencies from being included into the binary (SHOULD NOT be disabled on windows).

Enables crossterm_winapi and winapi

bracketed-paste default

Enables triggering a Event::Paste when pasting text into the terminal.

Affects event::EnableBracketedPaste, event::DisableBracketedPaste

event-stream = events

Enables async events

Enables futures-core

optional deps only added when requested

use-dev-tty = filedescriptor

Enables raw file descriptor polling / selecting instead of mio.

Enables process of rustix

events default event-stream?

Enables reading input/events from the system.

Enables mio, signal-hook, and signal-hook-mio

Affects event::EnableMouseCapture, crossterm::event, unix::supports_keyboard_enhancement, windows::supports_keyboard_enhancement

serde

Enables 'serde' for various types.

Enables serde, serde of bitflags

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

Shared dependencies

libc unix implicit feature

Enables libc

libc:

Raw FFI bindings to platform libraries like libc

Affects file_descriptor::FileDesc, file_descriptor::tty_fd

filedescriptor unix use-dev-tty?