Compare commits

...

29 Commits

Author SHA1 Message Date
Arthur Tazhitdinov
7ceca422c0
Merge 45c3850983 into f67c544e16 2026-02-02 21:28:59 +11:00
Arthur Tazhitdinov
45c3850983 revert to old style 2026-02-01 22:54:36 +03:00
Arthur Tazhitdinov
b213893644 stats as code 2026-02-01 22:46:56 +03:00
Arthur Tazhitdinov
f5dace7bed return pio.log 2026-02-01 22:42:32 +03:00
Arthur Tazhitdinov
b4cd58079d remove pr writer 2026-02-01 22:37:48 +03:00
Arthur Tazhitdinov
7b7337a366 remove pr writer 2026-02-01 22:36:34 +03:00
Arthur Tazhitdinov
88f8307cb1
Merge branch 'master' into chore-pr-firmware-stats 2026-02-02 00:20:48 +05:00
Arthur Tazhitdinov
b97224bc06
Enhance PR title check workflow with synchronization 2026-02-01 22:19:41 +03:00
Arthur Tazhitdinov
88c4181cb1
Add PR writer workflow for labeling and commenting
This workflow automates PR labeling and commenting with firmware build stats and artifact links.
2026-02-01 22:19:21 +03:00
Arthur Tazhitdinov
0c050ab33e
Apply suggestions from code review
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-01 22:17:07 +03:00
Arthur Tazhitdinov
f75c0c5aee format fixes 2026-02-01 22:12:48 +03:00
Arthur Tazhitdinov
cb9c17b80a format issues 2026-02-01 22:07:51 +03:00
Arthur Tazhitdinov
6297189e6f pr writer fixes 2026-02-01 21:56:20 +03:00
Arthur Tazhitdinov
9db4408750 update versions 2026-02-01 21:47:22 +03:00
Arthur Tazhitdinov
55d2c985c1 add pr-writer 2026-02-01 21:18:11 +03:00
Arthur Tazhitdinov
c572f4fffe try with no permissions 2026-02-01 17:15:31 +05:00
Arthur Tazhitdinov
e8e067da55 try permissions write-all 2026-02-01 17:11:27 +05:00
Arthur Tazhitdinov
7f08cc3667 try github-script v8 2026-02-01 17:07:10 +05:00
Arthur Tazhitdinov
ce204d1a8f try issues: write 2026-02-01 17:00:57 +05:00
Arthur Tazhitdinov
eebf9a7c9f revert repository-projects: write 2026-02-01 16:52:59 +05:00
Arthur Tazhitdinov
e3c799e05c
Update .github/workflows/pr-formatting-check.yml
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-01 16:51:19 +05:00
Arthur Tazhitdinov
328d504cb0 try repository-projects: write 2026-02-01 16:46:26 +05:00
Arthur Tazhitdinov
a540edd437 feat: capture short SHA for firmware artifact naming in PR comments 2026-01-30 22:51:28 +05:00
Arthur Tazhitdinov
c008d238d5 fix: update firmware artifact link in PR comment to point to the UI 2026-01-30 22:32:27 +05:00
Arthur Tazhitdinov
cb95ddbd04 feat: enhance PR commenting with firmware stats and upload firmware artifact 2026-01-30 22:24:51 +05:00
Arthur Tazhitdinov
826ccb2d25 fix: format firmware stats in PR comment as code block 2026-01-29 03:22:09 +05:00
Arthur Tazhitdinov
873611b989 chore: update CI workflows and add labeler configuration 2026-01-29 03:21:36 +05:00
Arthur Tazhitdinov
baebb3b2e2
Adjust condition for commenting PR with firmware stats 2026-01-29 03:08:02 +05:00
Arthur Tazhitdinov
ecc5057a1b feat: add firmware stats extraction and PR commenting 2026-01-29 02:52:33 +05:00

View File

@ -1,10 +1,55 @@
name: CI
'on':
name: CI (build)
on:
push:
branches: [master]
pull_request:
permissions:
contents: read
jobs:
clang-format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
submodules: recursive
- uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Install clang-format-21
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 21
sudo apt-get update
sudo apt-get install -y clang-format-21
- name: Run clang-format
run: |
PATH="/usr/lib/llvm-21/bin:$PATH" ./bin/clang-format-fix
git diff --exit-code || (echo "Please run 'bin/clang-format-fix' to fix formatting issues" && exit 1)
cppcheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
with:
submodules: recursive
- uses: actions/setup-python@v6
with:
python-version: '3.14'
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Run cppcheck
run: pio check --fail-on-defect low --fail-on-defect medium --fail-on-defect high
build:
runs-on: ubuntu-latest
steps:
@ -19,19 +64,28 @@ jobs:
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Install clang-format-21
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 21
sudo apt-get update
sudo apt-get install -y clang-format-21
- name: Run cppcheck
run: pio check --fail-on-defect low --fail-on-defect medium --fail-on-defect high
- name: Run clang-format
run: PATH="/usr/lib/llvm-21/bin:$PATH" ./bin/clang-format-fix && git diff --exit-code || (echo "Please run 'bin/clang-format-fix' to fix formatting issues" && exit 1)
- name: Build CrossPoint
run: pio run
run: |
set -euo pipefail
pio run | tee pio.log
- name: Extract firmware stats
run: |
set -euo pipefail
ram_line="$(grep -E "RAM:\\s" -m1 pio.log || true)"
flash_line="$(grep -E "Flash:\\s" -m1 pio.log || true)"
echo "ram_line=${ram_line}" >> "$GITHUB_OUTPUT"
echo "flash_line=${flash_line}" >> "$GITHUB_OUTPUT"
{
echo "## Firmware build stats"
if [ -n "$ram_line" ]; then echo "- ${ram_line}"; else echo "- RAM: not found"; fi
if [ -n "$flash_line" ]; then echo "- ${flash_line}"; else echo "- Flash: not found"; fi
} >> "$GITHUB_STEP_SUMMARY"
- name: Upload firmware.bin artifact
uses: actions/upload-artifact@v6
with:
name: firmware.bin
path: .pio/build/default/firmware.bin
if-no-files-found: error