Skip to content

Commit

Permalink
fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
srid committed Jul 9, 2024
1 parent b4bbac2 commit 8fb6958
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 2 additions & 5 deletions src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,11 +82,8 @@ impl CliArgs {
// Avoid using `--extra-experimental-features` if possible.
self.nixcmd = self.nixcmd.with_flakes().await?;
// Adjust to devour_flake's expectations
match &mut self.command {
Command::Build(build_cfg) => {
devour_flake::transform_override_inputs(&mut build_cfg.extra_nix_build_args);
}
_ => {}
if let Command::Build(build_cfg) = &mut self.command {
devour_flake::transform_override_inputs(&mut build_cfg.extra_nix_build_args);
}
Ok(())
}
Expand Down
2 changes: 1 addition & 1 deletion src/nix/devour_flake.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ pub async fn devour_flake(

/// Transform `--override-input` arguments to use `flake/` prefix, which
/// devour_flake expects.
pub fn transform_override_inputs(args: &mut Vec<String>) {
pub fn transform_override_inputs(args: &mut [String]) {
let mut iter = args.iter_mut().peekable();

while let Some(arg) = iter.next() {
Expand Down

0 comments on commit 8fb6958

Please sign in to comment.