1
1
mirror of https://github.com/theoludwig/libcproject.git synced 2024-11-14 16:03:13 +01:00
libcproject/.github/workflows/release.yml

60 lines
1.8 KiB
YAML
Raw Normal View History

2023-01-05 21:13:10 +01:00
name: 'Release'
on:
push:
branches: [master]
jobs:
release:
runs-on: 'ubuntu-latest'
steps:
- uses: 'actions/checkout@v3.5.3'
2023-01-05 21:13:10 +01:00
with:
fetch-depth: 0
persist-credentials: false
submodules: recursive
2023-01-05 21:13:10 +01:00
- name: 'Import GPG key'
uses: 'crazy-max/ghaction-import-gpg@v5.3.0'
2023-01-05 21:13:10 +01:00
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
git_user_signingkey: true
git_commit_gpgsign: true
2023-08-05 15:03:53 +02:00
- run: 'sudo apt update'
2023-01-05 21:13:10 +01:00
- name: 'Install Build Tools'
2023-08-05 15:03:53 +02:00
run: 'sudo apt-get install --yes build-essential gcc make clang-format'
- name: 'Install Documentation Tools'
run: 'sudo apt-get install --yes doxygen doxygen-gui doxygen-doc graphviz'
2023-01-05 21:13:10 +01:00
- run: 'make set_version'
- name: 'Use Node.js'
2023-08-05 15:03:53 +02:00
uses: 'actions/setup-node@v3.7.0'
2023-01-05 21:13:10 +01:00
with:
2023-08-05 15:03:53 +02:00
node-version: '18.17.0'
2023-01-05 21:13:10 +01:00
- name: 'Install Release Tools'
2023-08-05 15:03:53 +02:00
run: 'npm install --save-dev semantic-release@21.0.7 @commitlint/cli@17.6.7 @commitlint/config-conventional@17.6.7 @semantic-release/git@10.0.1 @semantic-release/exec@6.0.3 @saithodev/semantic-release-backmerge@3.2.0 vercel@31.2.2'
2023-01-05 21:13:10 +01:00
- run: 'rm --force package.json package-lock.json'
2023-01-05 21:13:10 +01:00
- name: 'Release'
2023-01-05 21:23:39 +01:00
run: 'npx semantic-release'
2023-01-05 21:13:10 +01:00
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GIT_COMMITTER_NAME: ${{ secrets.GIT_NAME }}
GIT_COMMITTER_EMAIL: ${{ secrets.GIT_EMAIL }}
2023-01-06 16:32:29 +01:00
- name: 'Generate Documentation'
run: 'make documentation'
2023-01-06 16:32:29 +01:00
- name: 'Deploy to Vercel'
run: 'npx vercel ./documentation/html --token="${VERCEL_TOKEN}" --prod'
env:
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}