mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-08-03 12:44:22 -07:00
Check ansible-output from CI instead of updating.
This commit is contained in:
parent
0741b65590
commit
6d60fd4f7e
1 changed files with 8 additions and 1 deletions
|
@ -6,10 +6,14 @@
|
|||
# dependencies = ["nox>=2025.02.09", "antsibull-nox"]
|
||||
# ///
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
import nox
|
||||
|
||||
# Whether the noxfile is running in CI:
|
||||
IN_CI = os.environ.get("CI") == "true"
|
||||
|
||||
|
||||
try:
|
||||
import antsibull_nox
|
||||
|
@ -43,7 +47,10 @@ def ansible_output(session: nox.Session) -> None:
|
|||
# Tools for post-processing
|
||||
"ruamel.yaml", # used by docs/docsite/reformat-yaml.py
|
||||
)
|
||||
session.run("antsibull-docs", "ansible-output", *session.posargs)
|
||||
args = []
|
||||
if IN_CI:
|
||||
args.append("--check")
|
||||
session.run("antsibull-docs", "ansible-output", *args, *session.posargs)
|
||||
|
||||
|
||||
# Allow to run the noxfile with `python noxfile.py`, `pipx run noxfile.py`, or similar.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue