summaryrefslogtreecommitdiff
path: root/src/bin
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2020-11-28 16:29:44 +0200
committerLars Wirzenius <liw@liw.fi>2020-11-28 17:03:45 +0200
commit2583b50e2a49fb0492ae0d341a51353b806c3233 (patch)
tree440f691dbf74da7fb17f7deaed9f43e130391787 /src/bin
parent8fae3c648d81d75510ecb68ed80d0042a5a2088f (diff)
downloadsummain-rs-2583b50e2a49fb0492ae0d341a51353b806c3233.tar.gz
feat! ManifestEntry::new now looks up metadata itself
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/summain.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/bin/summain.rs b/src/bin/summain.rs
index 056bc8b..0abe2f5 100644
--- a/src/bin/summain.rs
+++ b/src/bin/summain.rs
@@ -1,5 +1,4 @@
use anyhow::Context;
-use std::fs::symlink_metadata;
use std::path::{Path, PathBuf};
use structopt::StructOpt;
use summain::ManifestEntry;
@@ -20,8 +19,7 @@ struct Opt {
}
fn report(pathname: &Path) -> anyhow::Result<()> {
- let m = symlink_metadata(pathname)?;
- let e = ManifestEntry::new(pathname, m);
+ let e = ManifestEntry::new(pathname)?;
println!("{}", serde_yaml::to_string(&e)?);
Ok(())
}