Skip to content

Commit

Permalink
feat(ops/info): print lorri project file
Browse files Browse the repository at this point in the history
  • Loading branch information
Profpatsch committed Apr 14, 2024
1 parent 92b1bb5 commit 43f5409
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/ops.rs
Original file line number Diff line number Diff line change
Expand Up @@ -236,17 +236,22 @@ where
pub fn op_info(project: Project) -> Result<(), ExitError> {
let root_paths = project.root_paths();
let OutputPath { shell_gc_root } = &root_paths;

let gc_root = if root_paths.all_exist() {
format!("shell_gc_root: {}", shell_gc_root.0.display())
} else {
"GC roots do not exist. Has the project been built with lorri yet?".to_string()
};

print!(
"\
Lorri Project: {}
Garbage Collector Roots: {}
",
project.nix_file.display(),
gc_root
);

Ok(())
}

Expand Down

0 comments on commit 43f5409

Please sign in to comment.