Skip to content

Commit

Permalink
Merge pull request #41 from DanCardin/dc/fix-inverted-create-file-err…
Browse files Browse the repository at this point in the history
…or-handling
  • Loading branch information
DanCardin authored Oct 4, 2022
2 parents 050021c + 4fdee76 commit 5f86dff
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "sauce"
version = "0.7.1"
version = "0.7.2"
authors = ["Dan Cardin <[email protected]>"]
edition = "2021"
description = "A tool for managing directory-specific state."
Expand Down
4 changes: 2 additions & 2 deletions src/output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ impl Output {
let created = if self.show {
true
} else {
std::fs::create_dir_all(parent).is_err()
std::fs::create_dir_all(parent).is_ok()
};

if !created {
Expand All @@ -241,7 +241,7 @@ impl Output {
let created = if self.show {
true
} else {
std::fs::File::create(file).is_err()
std::fs::File::create(file).is_ok()
};

if !created {
Expand Down

0 comments on commit 5f86dff

Please sign in to comment.