decdn_common/cli/self_update.rs
1//! Arguments for the `decdn self-update` subcommand.
2
3use clap::Args;
4
5/// Replace the running `decdn` binary with the latest signed release.
6///
7/// The release's `SHA256SUMS.minisig` must verify against a minisign key this
8/// build embeds, and the archive must match the signed manifest, before any
9/// byte of the running binary changes. Only a binary the user can write and
10/// that `cargo install` did not place is replaced; the command names the path
11/// and the reason otherwise.
12#[derive(Args, Debug)]
13pub struct SelfUpdateArgs {
14 /// Report whether a newer signed release exists and whether this install
15 /// can be replaced; download no archive and change nothing.
16 #[arg(long)]
17 pub check: bool,
18}