Add nushell completion support (#2009)

* Add nushell completion support

Adds `clap_complete_nushell` crate and implements it into the `niri
completions` command.

* Add nushell to flake.nix autocompletions

* Convert to `TryFrom`

* Fix linting errors

* Move types down

---------

Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
This commit is contained in:
Artrix
2025-07-13 23:29:26 -07:00
committed by GitHub
parent 51b6a495c5
commit 746a7e81b7
5 changed files with 61 additions and 3 deletions
Generated
+11
View File
@@ -643,6 +643,16 @@ dependencies = [
"clap",
]
[[package]]
name = "clap_complete_nushell"
version = "4.5.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0a0c951694691e65bf9d421d597d68416c22de9632e884c28412cb8cd8b73dce"
dependencies = [
"clap",
"clap_complete",
]
[[package]]
name = "clap_derive"
version = "4.5.41"
@@ -2267,6 +2277,7 @@ dependencies = [
"calloop-wayland-source 0.4.0",
"clap",
"clap_complete",
"clap_complete_nushell",
"directories",
"drm-ffi",
"fastrand",