refactor(workflows): align GitHub workflow conventions
Cosmetic pass at aligning the conventions used in ZMK's workflows with GitHub's examples. Based on examples found at: https://github.com/actions/starter-workflows PR #433
This commit is contained in:
parent
e6d863c610
commit
7babe7f185
4 changed files with 23 additions and 30 deletions
21
.github/workflows/build.yml
vendored
21
.github/workflows/build.yml
vendored
|
@ -1,3 +1,5 @@
|
|||
name: Build
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
|
@ -8,12 +10,9 @@ on:
|
|||
- ".github/workflows/build.yml"
|
||||
- "app/**"
|
||||
|
||||
name: Build
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
name: Build Test
|
||||
strategy:
|
||||
matrix:
|
||||
board: [proton_c, nice_nano, bluemicro840_v1, nrfmicro_13]
|
||||
|
@ -47,8 +46,6 @@ jobs:
|
|||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
- name: Cache west modules
|
||||
timeout-minutes: 2
|
||||
continue-on-error: true
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-zephyr-modules
|
||||
|
@ -63,32 +60,34 @@ jobs:
|
|||
${{ runner.os }}-build-${{ env.cache-name }}-
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: West Init
|
||||
timeout-minutes: 2
|
||||
continue-on-error: true
|
||||
- name: West init
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-init
|
||||
with:
|
||||
args: 'init "-l app"'
|
||||
- name: West Update
|
||||
- name: West update
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-update
|
||||
with:
|
||||
args: "update"
|
||||
- name: West Config Zephyr Base
|
||||
- name: West config Zephyr base
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-config
|
||||
with:
|
||||
args: 'config "--global zephyr.base-prefer configfile"'
|
||||
- name: West Zephyr Export
|
||||
- name: West Zephyr export
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-zephyr-export
|
||||
with:
|
||||
args: "zephyr-export"
|
||||
- name: West Build
|
||||
- name: West build
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-build
|
||||
with:
|
||||
args: 'build "-s app -b ${{ matrix.board }} -- -DSHIELD=${{ matrix.shield }}"'
|
||||
- name: Archive Build
|
||||
- name: Archive build
|
||||
uses: actions/upload-artifact@v2
|
||||
if: ${{ matrix.board != 'proton_c' }}
|
||||
with:
|
||||
|
|
4
.github/workflows/clang-format-lint.yml
vendored
4
.github/workflows/clang-format-lint.yml
vendored
|
@ -1,4 +1,4 @@
|
|||
name: clang-format-lint
|
||||
name: Clang Format
|
||||
|
||||
on:
|
||||
push:
|
||||
|
@ -21,8 +21,6 @@ on:
|
|||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
name: clang-format lint
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: DoozyX/clang-format-lint-action@v0.9
|
||||
|
|
7
.github/workflows/doc-checks.yml
vendored
7
.github/workflows/doc-checks.yml
vendored
|
@ -1,4 +1,4 @@
|
|||
name: doc-checks
|
||||
name: Docs Checks
|
||||
|
||||
on:
|
||||
push:
|
||||
|
@ -13,8 +13,6 @@ on:
|
|||
jobs:
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
name: ESLint
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: bahmutov/npm-install@v1
|
||||
|
@ -26,12 +24,11 @@ jobs:
|
|||
prettier:
|
||||
runs-on: ubuntu-latest
|
||||
name: Prettier
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: bahmutov/npm-install@v1
|
||||
with:
|
||||
working-directory: docs
|
||||
- name: Prettier Check
|
||||
- name: Prettier check
|
||||
run: npm run prettier:check
|
||||
working-directory: docs
|
||||
|
|
21
.github/workflows/test.yml
vendored
21
.github/workflows/test.yml
vendored
|
@ -1,3 +1,5 @@
|
|||
name: Tests
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
|
@ -10,20 +12,15 @@ on:
|
|||
- "app/tests/**"
|
||||
- "app/src/**"
|
||||
|
||||
name: Test
|
||||
|
||||
jobs:
|
||||
integration_test:
|
||||
runs-on: ubuntu-latest
|
||||
name: Integration Tests
|
||||
steps:
|
||||
# To use this repository's private action,
|
||||
# you must check out the repository
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
- name: Cache west modules
|
||||
timeout-minutes: 2
|
||||
continue-on-error: true
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-zephyr-modules
|
||||
|
@ -38,33 +35,35 @@ jobs:
|
|||
${{ runner.os }}-build-${{ env.cache-name }}-
|
||||
${{ runner.os }}-build-
|
||||
${{ runner.os }}-
|
||||
- name: West Init
|
||||
timeout-minutes: 2
|
||||
continue-on-error: true
|
||||
- name: West init
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-init
|
||||
with:
|
||||
args: 'init "-l app"'
|
||||
- name: West Update
|
||||
- name: West update
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-update
|
||||
with:
|
||||
args: "update"
|
||||
- name: West Config Zephyr Base
|
||||
- name: West config Zephyr base
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-config
|
||||
with:
|
||||
args: 'config "--global zephyr.base-prefer configfile"'
|
||||
- name: West Zephyr Export
|
||||
- name: West Zephyr export
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-zephyr-export
|
||||
with:
|
||||
args: "zephyr-export"
|
||||
- name: Test All
|
||||
- name: Test all
|
||||
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
|
||||
id: west-build
|
||||
with:
|
||||
entrypoint: /bin/bash
|
||||
args: '-c "west test"'
|
||||
- name: Archive Build
|
||||
- name: Archive build
|
||||
if: ${{ always() }}
|
||||
uses: actions/upload-artifact@v2
|
||||
with:
|
||||
|
|
Loading…
Reference in a new issue