Skip to content

No-op non-windows enable_ansi_support function #30

Open
rustadopt/ansiterm-rs
#10
@daboross

Description

@daboross

Hi!

This looks like an awesome crate to use for colours. One question though: could a non-windows version of enable_ansi_support be added to the crate?

Ideally I'd rather not have my CLI applications having any OS-specific code - it would be nice if I could just stick ansi_term::enable_ansi_support() at the top of my main() function, and know that it'll do whatever's needed for the current OS.

It could just be literally #[cfg(not(windows))] fn enable_ansi_support() -> Result<(), u64> { Ok(()) }. If you'd be willing to add this, I can also submit a PR.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions