forked from riscv/riscv-crypto
-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (47 loc) · 1.62 KB
/
vector_build-pdf.yml
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
name: Create Crypto Vector Specification Document
# The workflow is triggered by pull request, push to main, and manual dispatch.
on:
workflow_dispatch:
pull_request:
push:
branches:
- main
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
# Step 1: Checkout the repository
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: 'recursive'
# Step 2: Pull the latest RISC-V Docs container image
- name: Pull Container
run: docker pull riscvintl/riscv-docs-base-container-image:latest
# Step 3: Build Vector Spec PDFs
- name: Build Crypto Vector Files
run: cd ./doc/vector && make
env:
VERSION: v${{ github.event.inputs.version }}
REVMARK: ${{ github.event.inputs.revision_mark }}
# Step 4: Upload the built vector PDF file
- name: Upload Crypto Vector Build Artifact
uses: actions/upload-artifact@v3
with:
name: Build Artifacts
path: ${{ github.workspace }}/doc/vector/*.pdf
retention-days: 30
# Create Release
- name: Create Crypto Vector Release
uses: softprops/action-gh-release@v1
with:
files: ${{ github.workspace }}/doc/vector/*.pdf
tag_name: v${{ github.event.inputs.version }}
name: Release ${{ github.event.inputs.version }}
draft: ${{ github.event.inputs.draft }}
prerelease: ${{ github.event.inputs.prerelease }}
env:
GITHUB_TOKEN: ${{ secrets.GHTOKEN }}
if: github.event_name == 'workflow_dispatch'
# This condition ensures this step only runs for workflow_dispatch events.