Compare commits

..

5 Commits

Author SHA1 Message Date
9131f84e63 Update actions/upload-artifact action to v4 2024-08-16 10:43:27 +00:00
af9390363a Update config/cradio.keymap
All checks were successful
Build / Build (push) Successful in 2m14s
2024-08-16 10:35:06 +00:00
20330bb4b7 Update config/cradio.keymap
All checks were successful
Build / Build (push) Successful in 2m9s
2024-08-16 10:29:37 +00:00
6a45824c88 Update .gitea/workflows/build.yaml
All checks were successful
Build / Build (push) Successful in 2m14s
2024-08-16 10:23:29 +00:00
f89a39f7da Update config/cradio.keymap
Some checks failed
Build / combine (push) Blocked by required conditions
Build / build-left (push) Has been cancelled
Build / build-right (push) Has been cancelled
2024-08-16 10:22:05 +00:00
2 changed files with 69 additions and 82 deletions

@ -1,111 +1,98 @@
name: Build on:
on:
push: push:
branches: branches:
- main - main
name: Build
jobs: jobs:
build-left: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
container: container:
image: zmkfirmware/zmk-build-arm:stable image: zmkfirmware/zmk-build-arm:stable
name: Build
steps: steps:
- name: Setup - name: Install Dependencies
run: | run: |
apt-get update; apt-get update;
apt-get install --yes --no-install-recommends nodejs zstd zip apt-get install --yes --no-install-recommends \
- name: Checkout code nodejs \
zstd \
zip
- name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Compute hash for west modules
- name: Hash west modules
id: hash-west id: hash-west
run: | run: |
HASH=$(find . -name 'build.yml' -o -name 'west.yml' -exec sha256sum {} \; | sort | sha256sum | head -c 64) FILE_PATH=zephyr/west.yml
FILES=$(find . -name build.yml -o -name west.yml -type f -exec sha256sum \; | sort)
HASH="$(echo -n $FILES | sha256sum | head -c 64)"
echo "hash=$HASH" >> "$GITHUB_OUTPUT" echo "hash=$HASH" >> "$GITHUB_OUTPUT"
echo "computed hash: $HASH"
- name: Cache west modules - name: Cache west modules
uses: actions/cache@v4 uses: actions/cache@v4
env:
cache-name: cache-zephyr-modules
with: with:
path: | path: |
modules/ modules/
tools/ tools/
zephyr/ zephyr/
bootloader/ bootloader/
key: ${{ runner.os }}-build-left-${{ steps.hash-west.outputs.hash }} key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ steps.hash-west.outputs.hash }}
- name: Initialize and update West restore-keys: |
run: | ${{ runner.os }}-build-${{ env.cache-name }}-
west init -l config ${{ runner.os }}-build-
west update ${{ runner.os }}-
west zephyr-export timeout-minutes: 5
- name: Build Firmware (Left) continue-on-error: true
- name: West Init
run: west init -l config
- name: West Update
run: west update
- name: West Zephyr export
run: west zephyr-export
- name: West Build (Ferris Left)
run: west build -s zmk/app -b nice_nano_v2 -- -DSHIELD=cradio_left -DZMK_CONFIG="${GITHUB_WORKSPACE}/config" run: west build -s zmk/app -b nice_nano_v2 -- -DSHIELD=cradio_left -DZMK_CONFIG="${GITHUB_WORKSPACE}/config"
- name: Rename and upload artifact (Left)
run: mv build/zephyr/zmk.uf2 cradio_left_nice_nano_v2.uf2
- uses: actions/upload-artifact@v4
with:
path: cradio_left_nice_nano_v2.uf2
name: left
build-right: - name: Ferris Left Kconfig file
runs-on: ubuntu-latest run: cat build/zephyr/.config | grep -v "^#" | grep -v "^$"
container:
image: zmkfirmware/zmk-build-arm:stable - name: Rename zmk.uf2
steps: run: cp build/zephyr/zmk.uf2 cradio_left_nice_nano_v2.uf2
- name: Setup
- name: West Build (Ferris Right)
run: west build --pristine -s zmk/app -b nice_nano_v2 -- -DSHIELD=cradio_right -DZMK_CONFIG="${GITHUB_WORKSPACE}/config"
- name: Ferris Right Kconfig file
run: cat build/zephyr/.config | grep -v "^#" | grep -v "^$"
- name: Rename zmk.uf2
run: cp build/zephyr/zmk.uf2 cradio_right_nice_nano_v2.uf2
- name: Move artifacts
run: | run: |
apt-get update; mkdir firmware
apt-get install --yes --no-install-recommends nodejs zstd zip mv cradio_left_nice_nano_v2.uf2 firmware/
- name: Checkout code mv cradio_right_nice_nano_v2.uf2 firmware/
uses: actions/checkout@v4
- name: Compute hash for west modules - name: Hash west modules
id: hash-west id: hash-west
run: | run: |
HASH=$(find . -name 'build.yml' -o -name 'west.yml' -exec sha256sum {} \; | sort | sha256sum | head -c 64) FILE_PATH=zephyr/west.yml
FILES=$(find . -name build.yml -o -name west.yml -type f -exec sha256sum \; | sort)
HASH="$(echo -n $FILES | sha256sum | head -c 64)"
echo "hash=$HASH" >> "$GITHUB_OUTPUT" echo "hash=$HASH" >> "$GITHUB_OUTPUT"
- name: Cache west modules echo "computed hash: $HASH"
uses: actions/cache@v4
with:
path: |
modules/
tools/
zephyr/
bootloader/
key: ${{ runner.os }}-build-right-${{ steps.hash-west.outputs.hash }}
- name: Initialize and update West
run: |
west init -l config
west update
west zephyr-export
- name: Build Firmware (Right)
run: west build --pristine -s zmk/app -b nice_nano_v2 -- -DSHIELD=cradio_right -DZMK_CONFIG="${GITHUB_WORKSPACE}/config"
- name: Rename and upload artifact (Right)
run: mv build/zephyr/zmk.uf2 cradio_right_nice_nano_v2.uf2
- uses: actions/upload-artifact@v4
with:
path: cradio_right_nice_nano_v2.uf2
name: right
combine: - name: Upload Artifact
needs:
- build-left
- build-right
runs-on: ubuntu-latest
container:
image: zmkfirmware/zmk-build-arm:stable
steps:
- name: Setup
run: |
apt-get update;
apt-get install --yes --no-install-recommends nodejs zip
- name: Download artifacts
uses: actions/download-artifact@v4
with:
name: left
path: firmware/
- uses: actions/download-artifact@v4
with:
name: right
path: firmware/
- name: Upload combined firmware artifacts
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
path: firmware/ path: firmware/

@ -11,7 +11,7 @@
&lt { &lt {
tapping-term-ms = <200>; tapping-term-ms = <200>;
quick-tap-ms = <150>; quick-tap-ms = <200>;
flavor = "tap-preferred"; flavor = "tap-preferred";
#binding-cells = <2>; #binding-cells = <2>;
}; };
@ -50,13 +50,13 @@
#binding-cells = <2>; #binding-cells = <2>;
flavor = "tap-preferred"; flavor = "tap-preferred";
tapping-term-ms = <200>; tapping-term-ms = <200>;
quick-tap-ms = <150>; quick-tap-ms = <200>;
require-prior-idle-ms = <100>; require-prior-idle-ms = <100>;
bindings = <&kp>, <&kp>; bindings = <&kp>, <&kp>;
}; };
lt: layer_tap { lt: layer_tap {
tapping-term-ms = <200>; tapping-term-ms = <200>;
quick-tap-ms = <150>; quick-tap-ms = <200>;
flavor = "tap-preferred"; flavor = "tap-preferred";
#binding-cells = <2>; #binding-cells = <2>;
}; };