[package]
edition = "2024"
rust-version = "1.85"
name = "keytap"
version = "0.4.0"
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Cross-platform, observe-only global keyboard taps with left/right modifier fidelity and clean shutdown"
readme = "README.md"
keywords = [
"keyboard",
"hotkey",
"global",
"input",
"evdev",
]
categories = [
"os",
"hardware-support",
"api-bindings",
]
license = "MIT OR Apache-2.0"
repository = "https://github.com/jamiepine/keytap"
[features]
chord = []
default = ["chord"]
serde = ["dep:serde"]
tracing = ["dep:tracing"]
[lib]
name = "keytap"
path = "src/lib.rs"
[[example]]
name = "chord"
path = "examples/chord.rs"
[[example]]
name = "raw"
path = "examples/raw.rs"
[dependencies.crossbeam-channel]
version = "0.5"
[dependencies.serde]
version = "1"
features = ["derive"]
optional = true
[dependencies.thiserror]
version = "2"
[dependencies.tracing]
version = "0.1"
optional = true
[dev-dependencies.anyhow]
version = "1"
[dev-dependencies.serde_json]
version = "1"
[target.'cfg(target_os = "linux")'.dependencies.evdev]
version = "0.13"
[target.'cfg(target_os = "linux")'.dependencies.nix]
version = "0.29"
features = [
"poll",
"event",
]
[target.'cfg(target_os = "macos")'.dependencies.libc]
version = "0.2"
[target.'cfg(target_os = "macos")'.dependencies.objc2]
version = "0.6"
[target.'cfg(target_os = "macos")'.dependencies.objc2-core-foundation]
version = "0.3"
features = [
"std",
"CFRunLoop",
"CFMachPort",
]
default-features = false
[target.'cfg(target_os = "macos")'.dependencies.objc2-core-graphics]
version = "0.3"
features = [
"std",
"CGEvent",
"CGEventTypes",
]
default-features = false
[target.'cfg(target_os = "macos")'.dependencies.objc2-foundation]
version = "0.3"
features = [
"std",
"NSAutoreleasePool",
]
default-features = false
[target.'cfg(target_os = "windows")'.dependencies.windows-sys]
version = "0.59"
features = [
"Win32_UI_WindowsAndMessaging",
"Win32_UI_Input_KeyboardAndMouse",
"Win32_Foundation",
"Win32_System_Threading",
"Win32_System_LibraryLoader",
]