test #12
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build QMK firmware | |
on: [push, workflow_dispatch] | |
permissions: | |
contents: write | |
jobs: | |
build: | |
name: 'QMK Userspace Build' | |
uses: qmk/.github/.github/workflows/qmk_userspace_build.yml@main | |
with: | |
qmk_repo: qmk/qmk_firmware | |
qmk_ref: master | |
publish: | |
name: 'QMK Userspace Publish' | |
uses: qmk/.github/.github/workflows/qmk_userspace_publish.yml@main | |
if: always() && !cancelled() | |
needs: build | |
generate_keymaps: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Install pipx | |
run: | | |
python -m pip install --user pipx | |
python -m pipx ensurepath | |
export PATH=$PATH:~/.local/bin # Ensure pipx is in PATH | |
- name: Install keymap-drawer using pipx | |
run: | | |
pipx install keymap-drawer | |
- name: Generate keymap | |
run: | | |
keymap parse -c 12 -q keyboards/crkbd/keymap.json > pre-draw-phase.yml | |
keymap draw pre-draw-phase.yml > layout.svg | |
- name: Commit and push changes | |
run: | | |
git config --local user.name "github-actions[bot]" | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git add . | |
git commit -m "Auto-generated keymap from JSON" | |
git push | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |