Skip to content

Commit

Permalink
Fix unsupported fallback impl
Browse files Browse the repository at this point in the history
  • Loading branch information
bash committed Jan 19, 2024
1 parent 1f0cbd5 commit f2f1f4e
Show file tree
Hide file tree
Showing 3 changed files with 81 additions and 14 deletions.
87 changes: 77 additions & 10 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ thiserror = "1.0.56"
[target.'cfg(unix)'.dependencies]
libc = "0.2.151"
mio = { version = "0.8.10", features = ["os-poll", "os-ext"], default-features = false }
terminal-trx = { git = "https://github.com/bash/terminal-trx" }
terminal-trx = { git = "https://github.com/bash/terminal-trx", branch = "windows" }

[workspace]
members = [
Expand Down
6 changes: 3 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,13 +125,13 @@ pub fn background_color(options: QueryOptions) -> Result<Color> {

#[cfg(not(unix))]
mod unsupported {
use crate::{Color, Error, Result};
use crate::{Color, Error, QueryOptions, Result};

pub(crate) fn foreground_color() -> Result<Color> {
pub(crate) fn foreground_color(_options: QueryOptions) -> Result<Color> {
Err(Error::UnsupportedTerminal)
}

pub(crate) fn background_color() -> Result<Color> {
pub(crate) fn background_color(_options: QueryOptions) -> Result<Color> {
Err(Error::UnsupportedTerminal)
}
}

0 comments on commit f2f1f4e

Please sign in to comment.