Skip to content

Commit 475443b

Browse files
build(deps): bump flexi_logger from 0.17.1 to 0.18.0 (#72)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Yoann Fleury <yoann.fleury@yahoo.com>
1 parent 19201d6 commit 475443b

3 files changed

Lines changed: 8 additions & 5 deletions

File tree

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ version = "0.3.1"
1919

2020
[dependencies]
2121
anyhow = "1.0"
22-
flexi_logger = "0.17"
22+
flexi_logger = "0.18"
2323
git-url-parse = "0.3"
2424
git2 = "0.13"
2525
log = "0.4"

src/main.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,16 @@ use structopt::StructOpt;
88
extern crate log;
99

1010
fn main() {
11-
// Get the command line options
11+
// Get the command line options.
1212
let opt = Opt::from_args();
1313

14-
Logger::with_str(if opt.verbose { "debug" } else { "info" })
14+
// Enable the logger with the output mode based on the given option.
15+
Logger::try_with_str(if opt.verbose { "debug" } else { "info" })
16+
.unwrap()
1517
.start()
1618
.unwrap_or_else(|e| panic!("Logger initialization failed with {}", e));
1719

20+
// Run the program using the given options.
1821
match run(opt) {
1922
Ok(_) => (),
2023
Err(err) => {

0 commit comments

Comments
 (0)