From b3aa0a08848ccd01cd7a4ecef6ff5bf46719af85 Mon Sep 17 00:00:00 2001 From: 魏曹先生 <1992414357@qq.com> Date: Tue, 18 Aug 2026 09:07:22 +0800 Subject: feat(ci-new): add report-clean command to remove collected logs and report --- mingling_ci/src/cmd/cmd_report_collect.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'mingling_ci/src/cmd/cmd_report_collect.rs') diff --git a/mingling_ci/src/cmd/cmd_report_collect.rs b/mingling_ci/src/cmd/cmd_report_collect.rs index bb944b3..3cebaef 100644 --- a/mingling_ci/src/cmd/cmd_report_collect.rs +++ b/mingling_ci/src/cmd/cmd_report_collect.rs @@ -8,10 +8,9 @@ use mingling::{ }; use crate::Next; -use crate::reporter::COLLECT_DIR; +use crate::reporter::{COLLECT_DIR, REPORT_PATH}; use crate::res::{CargoError, Manifests, MessagePrinter, ResCollectLogs}; -const OUTPUT_PATH: &str = "./.temp/reports/result.md"; const REPORT_TEMPLATE: &str = include_str!("../../tmpls/report.md"); const TASK_SECTION_TEMPLATE: &str = include_str!("../../tmpls/task_section.md"); @@ -93,7 +92,7 @@ pub fn report_collect(manifests: &Manifests, logs: &ResCollectLogs) -> Next { *template.add_impl("task_sections".to_string()) = sections; let expanded = template.expand().unwrap_or_default(); - let output = PathBuf::from(OUTPUT_PATH); + let output = PathBuf::from(REPORT_PATH); let parent = output.parent().expect("output path has a parent"); if let Err(e) = std::fs::create_dir_all(parent).and_then(|()| std::fs::write(&output, expanded)) -- cgit