-
-
Notifications
You must be signed in to change notification settings - Fork 406
71 lines (61 loc) · 2.11 KB
/
release.yaml
File metadata and controls
71 lines (61 loc) · 2.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Release docs
# checks are only on the draft directory because the release directory will be overwritten
on:
push:
# tagged x.x.x releases as well as release candidates
tags:
- ?.?.?*
workflow_dispatch:
# for security reasons the github actions are pinned to specific SHAs
jobs:
export_pdf:
name: Export PDF
runs-on: ubuntu-24.04
steps:
- name: Checkout markdown
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
- name: Install python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405
with:
python-version: 3.x
- name: Install python packages
run: |
python -m pip install --upgrade pip setuptools wheel
pip install mkdocs
pip install mkdocs-material
pip install mkdocs-open-in-new-tab
pip install mkdocs-redirects
pip install mkdocs-with-pdf
- name: Build
run: mkdocs build
- name: Upload PDF
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f
with:
name: 'pdf-export'
path: 'site/OWASP_Developer_Guide.pdf'
draft_release:
name: Create draft release
runs-on: ubuntu-24.04
needs: [export_pdf]
steps:
- name: Check out
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
- name: Fetch prepared SBOM artifacts
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
with:
name: 'pdf-export'
path: 'site/OWASP_Developer_Guide.pdf'
- name: Prepare release notes
run: |
releaseVersion=${{ github.ref_name }}
sed -e s/x.x.x/${releaseVersion:1}/g .release-note-template.md > ./release-notes.txt
- name: Create release notes
uses: softprops/action-gh-release@153bb8e04406b158c6c84fc1615b65b24149a1fe
with:
draft: true
name: "${releaseVersion:1}"
append_body: true
body_path: ./release-notes.txt
generate_release_notes: true
files: |
site/OWASP_Developer_Guide.pdf