Merge remote-tracking branch 'origin/main' into rename
This commit is contained in:
@@ -120,11 +120,15 @@ def check_version_output(report: Report, project: Path) -> None:
|
||||
out_lines = [ln.lstrip()[5:] for ln in result.stdout.splitlines() if ln.lstrip().startswith("echo ")]
|
||||
out = "\n".join(out_lines).strip()
|
||||
single = len(out.splitlines()) == 1 and out != ""
|
||||
no_v = single and not out.startswith("v")
|
||||
detail = f"stdout={out!r}"
|
||||
if single and not no_v:
|
||||
detail += "\ncanonical version must not start with 'v'"
|
||||
report.add(
|
||||
PASS if single else FAIL,
|
||||
PASS if no_v else FAIL,
|
||||
3,
|
||||
"version 输出一行非空版本号",
|
||||
f"stdout={out!r}",
|
||||
"version 输出一行非空规范版本(无 v 前缀)",
|
||||
detail,
|
||||
)
|
||||
|
||||
|
||||
@@ -331,7 +335,7 @@ def main(argv: list[str] | None = None) -> int:
|
||||
check_build_has_no_upload(report, project)
|
||||
else:
|
||||
report.add(SKIP, 2, "ARCH 守卫与缺省值", "(build target missing)")
|
||||
report.add(SKIP, 3, "version 输出一行非空版本号", "(version target missing)")
|
||||
report.add(SKIP, 3, "version 输出一行非空规范版本(无 v 前缀)", "(version target missing)")
|
||||
report.add(SKIP, 4, "build 不含上传动作", "(build target missing)")
|
||||
|
||||
if deb_project:
|
||||
|
||||
Reference in New Issue
Block a user