Update nsc-helper crates

This commit is contained in:
Victor Fuentes 2022-10-28 10:48:16 -04:00
parent 0ff92e7cc9
commit 0bf5c77fff
No known key found for this signature in database
GPG Key ID: 0A88B68D6A9ACAE0
3 changed files with 12 additions and 57 deletions

57
Cargo.lock generated
View File

@ -285,28 +285,11 @@ dependencies = [
"atty",
"bitflags",
"strsim 0.8.0",
"textwrap 0.11.0",
"textwrap",
"unicode-width",
"vec_map",
]
[[package]]
name = "clap"
version = "3.2.23"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5"
dependencies = [
"atty",
"bitflags",
"clap_derive 3.2.18",
"clap_lex 0.2.4",
"indexmap",
"once_cell",
"strsim 0.10.0",
"termcolor",
"textwrap 0.16.0",
]
[[package]]
name = "clap"
version = "4.0.18"
@ -315,26 +298,13 @@ checksum = "335867764ed2de42325fafe6d18b8af74ba97ee0c590fa016f157535b42ab04b"
dependencies = [
"atty",
"bitflags",
"clap_derive 4.0.18",
"clap_lex 0.3.0",
"clap_derive",
"clap_lex",
"once_cell",
"strsim 0.10.0",
"termcolor",
]
[[package]]
name = "clap_derive"
version = "3.2.18"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ea0c8bce528c4be4da13ea6fead8965e95b6073585a2f05204bd8f4119f82a65"
dependencies = [
"heck",
"proc-macro-error",
"proc-macro2",
"quote",
"syn",
]
[[package]]
name = "clap_derive"
version = "4.0.18"
@ -348,15 +318,6 @@ dependencies = [
"syn",
]
[[package]]
name = "clap_lex"
version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2850f2f5a82cbf437dd5af4d49848fbdfc27c157c3d010345776f952765261c5"
dependencies = [
"os_str_bytes",
]
[[package]]
name = "clap_lex"
version = "0.3.0"
@ -1744,7 +1705,7 @@ dependencies = [
name = "nsc-helper"
version = "0.1.0"
dependencies = [
"clap 3.2.23",
"clap 4.0.18",
"users",
]
@ -1847,9 +1808,9 @@ dependencies = [
[[package]]
name = "os_str_bytes"
version = "6.3.0"
version = "6.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9ff7415e9ae3fff1225851df9e0d9e4e5479f947619774677a63572e55e80eff"
checksum = "3baf96e39c5359d2eb0dd6ccb42c62b91d9678aa68160d261b9e0ccbf9e9dea9"
[[package]]
name = "owo-colors"
@ -2776,12 +2737,6 @@ dependencies = [
"unicode-width",
]
[[package]]
name = "textwrap"
version = "0.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d"
[[package]]
name = "thiserror"
version = "1.0.37"

View File

@ -4,7 +4,7 @@ version = "0.1.0"
edition = "2021"
[dependencies]
clap = { version = "3.2", features = ["derive"] }
clap = { version = "4.0", features = ["derive"] }
users = "0.11"
[[bin]]

View File

@ -6,11 +6,11 @@ use std::{
process::Command,
};
#[derive(clap::Subcommand)]
#[derive(Subcommand, Debug)]
enum SubCommands {
Config {
/// Write stdin to file in path output
#[clap(short, long)]
#[arg(short, long)]
output: String,
/// Run `nixos-rebuild` with the given arguments
arguments: Vec<String>,
@ -21,17 +21,17 @@ enum SubCommands {
},
Channel {
/// Whether to rebuild the system after updating channels
#[clap(short, long)]
#[arg(short, long)]
rebuild: bool,
/// Run `nixos-rebuild` with the given arguments
arguments: Vec<String>,
},
Flake {
/// Whether to rebuild the system after updating flake
#[clap(short, long)]
#[arg(short, long)]
rebuild: bool,
/// Path to the flake file
#[clap(short, long)]
#[arg(short, long)]
flakepath: String,
/// Run `nixos-rebuild` with the given arguments
arguments: Vec<String>,