Skip to content

Commit e12082c

Browse files
committed
Fix building documentation for Anope tags.
1 parent 4a0cf55 commit e12082c

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
runs-on: ubuntu-latest
2020
env:
2121
ANOPE_BRANCHES: 2.0 2.1
22-
ANOPE_TAGS: 2.0 2.1
22+
ANOPE_TAGS: 2.1
2323
environment:
2424
name: github-pages
2525
url: ${{ steps.deployment.outputs.page_url }}

mkapi

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ with tempfile.TemporaryDirectory() as git:
5959
for tag in subprocess.check_output([GIT, 'tag', '--list', '--sort', '-v:refname'], encoding='utf-8').split('\n'):
6060
for tag_prefix in ANOPE_TAGS:
6161
if tag.startswith(tag_prefix):
62-
versions = re.match(r'^v((((\d+)\.\d+)\.\d+).*)', tag)
62+
versions = re.match(r'^((((\d+)\.\d+)\.\d+).*)', tag)
6363
if not versions:
6464
continue
6565
if not tag in references:
@@ -73,6 +73,10 @@ with tempfile.TemporaryDirectory() as git:
7373
if os.system(f"{GIT} clean -dfx && {GIT} reset --hard && {GIT} checkout {reference}"):
7474
sys.exit(1)
7575

76+
if not os.path.exists("docs/Doxyfile"):
77+
print(f"Skipping API docs for {CC_BOLD}{reference}{CC_RESET} as it lacks a Doxyfile!")
78+
continue
79+
7680
print(f"Building API docs for {CC_BOLD}{reference}{CC_RESET} ...")
7781
with open("docs/Doxyfile", "a") as fh:
7882
fh.write(f"PROJECT_NUMBER = {reference}")

0 commit comments

Comments
 (0)