mirror of https://github.com/helix-editor/helix
load coverage file from environment variable
parent
6006a69b44
commit
79b85030b2
|
@ -151,7 +151,8 @@ pub fn coverage<'doc>(
|
|||
) -> GutterFn<'doc> {
|
||||
let covered = theme.get("diff.plus.gutter");
|
||||
let not_covered = theme.get("diff.minus.gutter");
|
||||
if let Some(cov) = coverage::parse(PathBuf::from("report/coverage.xml")) {
|
||||
if let Ok(coverage_path) = std::env::var("HELIX_COVERAGE_FILE") {
|
||||
if let Some(cov) = coverage::parse(PathBuf::from(coverage_path)) {
|
||||
if let Some(mut path) = doc.path.clone() {
|
||||
if let Ok(cwd) = std::env::current_dir() {
|
||||
if let Ok(tmp) = path.strip_prefix(cwd) {
|
||||
|
@ -183,6 +184,7 @@ pub fn coverage<'doc>(
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return Box::new(move |_, _, _, _| None);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue