Skip to content

Commit 2914c31

Browse files
committed
install: Use a default derive
Minor cleanup. Signed-off-by: Colin Walters <[email protected]>
1 parent 5c9e00a commit 2914c31

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

lib/src/install/baseline.rs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@ impl Display for Filesystem {
5050
}
5151
}
5252

53-
#[derive(clap::ValueEnum, Debug, Copy, Clone, PartialEq, Eq, Serialize, Deserialize)]
53+
#[derive(clap::ValueEnum, Default, Debug, Copy, Clone, PartialEq, Eq, Serialize, Deserialize)]
5454
#[serde(rename_all = "kebab-case")]
5555
pub(crate) enum BlockSetup {
56+
#[default]
5657
Direct,
5758
Tpm2Luks,
5859
}
@@ -63,12 +64,6 @@ impl Display for BlockSetup {
6364
}
6465
}
6566

66-
impl Default for BlockSetup {
67-
fn default() -> Self {
68-
Self::Direct
69-
}
70-
}
71-
7267
/// Options for installing to a block device
7368
#[derive(Debug, Clone, clap::Args, Serialize, Deserialize, PartialEq, Eq)]
7469
#[serde(rename_all = "kebab-case")]

0 commit comments

Comments
 (0)