Skip to content

Commit

Permalink
fix: trim the version string
Browse files Browse the repository at this point in the history
  • Loading branch information
shivaraj-bh committed Mar 19, 2024
1 parent af3027b commit f2b53bc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion crates/nix_health/src/check/direnv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,8 @@ fn direnv_version() -> anyhow::Result<String> {
.output()?;
if output.status.success() {
let out = String::from_utf8_lossy(&output.stdout);
Ok(out.to_string())
let trimmed_out = out.trim();
Ok(trimmed_out.to_string())
} else {
anyhow::bail!("Unable to run direnv --version: {:?}", output.stderr)
}
Expand Down

0 comments on commit f2b53bc

Please sign in to comment.