| 258 | /// Set the default identity. |
| 259 | #[derive(Debug, clap::Args)] |
| 260 | pub struct Default { |
| 261 | /// Name of the identity to set as default. |
| 262 | /// |
| 263 | /// If not provided with --clear, this is required. |
| 264 | #[arg(required_unless_present = "clear")] |
| 265 | pub name: Option<String>, |
| 266 | |
| 267 | /// Usage context to set the default for. |
| 268 | /// |
| 269 | /// If not specified, sets the global default. |
| 270 | #[arg(long, short = 'u')] |
| 271 | pub usage: Option<String>, |
| 272 | |
| 273 | /// Clear the default identity instead of setting one. |
| 274 | #[arg(long, conflicts_with = "name")] |
| 275 | pub clear: bool, |
| 276 | } |
| 277 | |
| 278 | impl Command for Default { |
| 279 | fn run(&self) -> CliResult<()> { |
nothing calls this directly
no outgoing calls
no test coverage detected