mirror of
https://github.com/sysprog21/lkmpg.git
synced 2025-02-10 23:55:17 +08:00
![linD026](/assets/img/avatar_default.png)
Cppcheck[1] is integrated into CI pipeline for running static analysis. However, Cppcheck is known to report false-positive, and we have to suppress some warnings in advance. [1] https://cppcheck.sourceforge.io/
52 lines
1.2 KiB
YAML
52 lines
1.2 KiB
YAML
name: build-deploy-assets
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
container: twtug/lkmpg
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Build
|
|
run: |
|
|
make all
|
|
make html
|
|
tar zcvf lkmpg-html.tar.gz ./html
|
|
- name: Delete old release asset
|
|
uses: mknejp/delete-release-assets@v1
|
|
with:
|
|
token: ${{ github.token }}
|
|
fail-if-no-assets: false
|
|
tag: latest
|
|
assets: |
|
|
lkmpg.pdf
|
|
lkmpg-html.tar.gz
|
|
- name: Release
|
|
uses: softprops/action-gh-release@v0.1.8
|
|
with:
|
|
files: |
|
|
lkmpg.pdf
|
|
lkmpg-html.tar.gz
|
|
tag_name: "latest"
|
|
prerelease: true
|
|
|
|
validate:
|
|
runs-on: ubuntu-20.04
|
|
steps:
|
|
- name: checkout code
|
|
uses: actions/checkout@v2
|
|
- name: validate coding style and functionality
|
|
run: |
|
|
sudo apt-get install -q -y clang-format-11
|
|
sudo apt-get install -q -y cppcheck
|
|
.ci/check-format.sh
|
|
.ci/static-analysis.sh
|
|
.ci/build-n-run.sh
|
|
shell: bash
|