Skip to content

Commit

Permalink
fix build/clippy issues
Browse files Browse the repository at this point in the history
  • Loading branch information
sbstp committed Jul 29, 2023
1 parent ae1fb72 commit 426d4e1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/cmd/export.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use anyhow::{anyhow, Result};

use crate::kubeconfig::{self, KubeConfig};
use crate::settings::{ContextHeaderBehavior, Settings};
use crate::kubeconfig::{self};
use crate::settings::Settings;

pub fn export(settings: &Settings, context_name: String, namespace_name: String) -> Result<()> {
let installed = kubeconfig::get_installed_contexts(settings)?;
Expand All @@ -17,7 +17,7 @@ pub fn export(settings: &Settings, context_name: String, namespace_name: String)
.prefix("kubie-config")
.suffix(".yaml")
.tempfile()?;
kubeconfig.write_to(&temp_config_file)?;
kubeconfig.write_to_file(temp_config_file.path())?;
println!("{}", temp_config_file.path().display());
}

Expand Down
3 changes: 1 addition & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,8 @@ fn main() -> Result<()> {
Kubie::Export {
context_name,
namespace_name,
args,
} => {
cmd::export::export(&settings, context_name, namespace_name, args)?;
cmd::export::export(&settings, context_name, namespace_name)?;
}
}

Expand Down

0 comments on commit 426d4e1

Please sign in to comment.