Skip to content

Commit 1b9e7ac

Browse files
committed
Allow some unused lints
We still probably don't want unused imports or variables to cause warnings, but this codebase is large enough that warning on unconsumed errors or mut's are a good idea. Signed-off-by: Robert Detjens <[email protected]>
1 parent bf69825 commit 1b9e7ac

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

src/builder/artifacts.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ pub fn zip_files(archive_name: &Path, files: &[PathBuf]) -> Result<PathBuf> {
216216
buf.clear();
217217
}
218218

219-
z.finish();
219+
z.finish()?;
220220

221221
Ok(archive_name.to_path_buf())
222222
}

src/builder/docker.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ pub async fn copy_file(container: &ContainerInfo, from: &Path, to: &Path) -> Res
194194

195195
// extract single file from archive to disk
196196
// we only copied out one file, so this tar should only have one file
197-
if let Some(mut entry_r) = tar.entries()?.next() {
197+
if let Some(entry_r) = tar.entries()?.next() {
198198
let mut entry = entry_r?;
199199
trace!("got entry: {:?}", entry.path());
200200
let mut target = File::create(to)?;

src/cluster_setup/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ fn install_helm_chart(
155155

156156
// stream output to stdout
157157
let reader = helm_cmd.reader()?;
158-
let mut lines = BufReader::new(reader).lines();
158+
let lines = BufReader::new(reader).lines();
159159

160160
for item in lines {
161161
match item {

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#![allow(unused)]
1+
#![allow(unused_variables, unused_imports)]
22
// todo!: remove ^ later
33
// we dont need unused variables etc warnings while we're working on it
44

0 commit comments

Comments
 (0)