From e4a6afa369ca695be97dc3ba96fe129a1c24456e Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sun, 27 Feb 2022 11:28:51 +0000 Subject: Rework generate-api CLI command to use .build directory (#16441) --- .github/workflows/api.yml | 2 +- .github/workflows/develop_api.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to '.github') diff --git a/.github/workflows/api.yml b/.github/workflows/api.yml index a19667f97e..f0c49baf60 100644 --- a/.github/workflows/api.yml +++ b/.github/workflows/api.yml @@ -35,4 +35,4 @@ jobs: AWS_ACCESS_KEY_ID: ${{ secrets.SPACES_ACCESS_KEY }} AWS_SECRET_ACCESS_KEY: ${{ secrets.SPACES_SECRET_KEY }} AWS_S3_ENDPOINT: https://nyc3.digitaloceanspaces.com - SOURCE_DIR: 'api_data' + SOURCE_DIR: '.build/api_data' diff --git a/.github/workflows/develop_api.yml b/.github/workflows/develop_api.yml index f0098142c7..3eb6e53c20 100644 --- a/.github/workflows/develop_api.yml +++ b/.github/workflows/develop_api.yml @@ -35,4 +35,4 @@ jobs: AWS_ACCESS_KEY_ID: ${{ secrets.SPACES_ACCESS_KEY }} AWS_SECRET_ACCESS_KEY: ${{ secrets.SPACES_SECRET_KEY }} AWS_S3_ENDPOINT: https://nyc3.digitaloceanspaces.com - SOURCE_DIR: 'api_data' + SOURCE_DIR: '.build/api_data' -- cgit v1.2.3 From 4f30b7a2c9d04070f1df8936bf3e75eee14558bc Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sat, 2 Apr 2022 22:09:16 +0100 Subject: Automatically approve workflow runs from first time contributors (#16774) --- .github/workflows/auto_approve.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/workflows/auto_approve.yml (limited to '.github') diff --git a/.github/workflows/auto_approve.yml b/.github/workflows/auto_approve.yml new file mode 100644 index 0000000000..7c0a982b44 --- /dev/null +++ b/.github/workflows/auto_approve.yml @@ -0,0 +1,16 @@ +name: Automatic Approve + +on: + schedule: + - cron: "*/5 * * * *" + +jobs: + automatic_approve: + runs-on: ubuntu-latest + + steps: + uses: mheap/automatic-approve-action@v1 + with: + token: ${{ secrets.QMK_BOT_TOKEN }} + workflows: "format.yml,lint.yml,unit_test.yml" + dangerous_files: "lib/python/,Makefile,paths.mk,builddefs/" -- cgit v1.2.3 From 61bd61347ab1739524f375871407d54436f4c68e Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sat, 2 Apr 2022 22:28:10 +0100 Subject: Automatically approve workflow runs from first time contributors (#16775) * Automatically approve workflow runs from first time contributors * Automatically approve workflow runs from first time contributors --- .github/workflows/auto_approve.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to '.github') diff --git a/.github/workflows/auto_approve.yml b/.github/workflows/auto_approve.yml index 7c0a982b44..6b986ffccc 100644 --- a/.github/workflows/auto_approve.yml +++ b/.github/workflows/auto_approve.yml @@ -9,8 +9,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: mheap/automatic-approve-action@v1 - with: - token: ${{ secrets.QMK_BOT_TOKEN }} - workflows: "format.yml,lint.yml,unit_test.yml" - dangerous_files: "lib/python/,Makefile,paths.mk,builddefs/" + - uses: mheap/automatic-approve-action@v1 + with: + token: ${{ secrets.QMK_BOT_TOKEN }} + workflows: "format.yml,lint.yml,unit_test.yml" + dangerous_files: "lib/python/,Makefile,paths.mk,builddefs/" -- cgit v1.2.3 From 27ae37d626ca534be196bf4a0bdffa8e03a5a159 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sun, 3 Apr 2022 13:18:28 +0100 Subject: Align action workflow filenames (#16776) --- .github/workflows/auto_tag.yaml | 33 ------------------------ .github/workflows/auto_tag.yml | 33 ++++++++++++++++++++++++ .github/workflows/format.yaml | 51 -------------------------------------- .github/workflows/format.yml | 51 ++++++++++++++++++++++++++++++++++++++ .github/workflows/format_push.yaml | 49 ------------------------------------ .github/workflows/format_push.yml | 49 ++++++++++++++++++++++++++++++++++++ 6 files changed, 133 insertions(+), 133 deletions(-) delete mode 100644 .github/workflows/auto_tag.yaml create mode 100644 .github/workflows/auto_tag.yml delete mode 100644 .github/workflows/format.yaml create mode 100644 .github/workflows/format.yml delete mode 100644 .github/workflows/format_push.yaml create mode 100644 .github/workflows/format_push.yml (limited to '.github') diff --git a/.github/workflows/auto_tag.yaml b/.github/workflows/auto_tag.yaml deleted file mode 100644 index 29e85c41ca..0000000000 --- a/.github/workflows/auto_tag.yaml +++ /dev/null @@ -1,33 +0,0 @@ -name: Essential files modified - -on: - push: - branches: - - master - paths: - - quantum/**/* - - tmk_core/**/* - - drivers/**/* - - tests/**/* - - util/**/* - - platforms/**/* - - Makefile - - '*.mk' - -jobs: - tag: - runs-on: ubuntu-latest - - # protect against those who develop with their fork on master - if: github.repository == 'qmk/qmk_firmware' - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - - name: Bump version and push tag - uses: anothrNick/github-tag-action@1.26.0 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - DEFAULT_BUMP: 'patch' diff --git a/.github/workflows/auto_tag.yml b/.github/workflows/auto_tag.yml new file mode 100644 index 0000000000..29e85c41ca --- /dev/null +++ b/.github/workflows/auto_tag.yml @@ -0,0 +1,33 @@ +name: Essential files modified + +on: + push: + branches: + - master + paths: + - quantum/**/* + - tmk_core/**/* + - drivers/**/* + - tests/**/* + - util/**/* + - platforms/**/* + - Makefile + - '*.mk' + +jobs: + tag: + runs-on: ubuntu-latest + + # protect against those who develop with their fork on master + if: github.repository == 'qmk/qmk_firmware' + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Bump version and push tag + uses: anothrNick/github-tag-action@1.26.0 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + DEFAULT_BUMP: 'patch' diff --git a/.github/workflows/format.yaml b/.github/workflows/format.yaml deleted file mode 100644 index ba0a86aa78..0000000000 --- a/.github/workflows/format.yaml +++ /dev/null @@ -1,51 +0,0 @@ -name: PR Lint Format - -on: - pull_request: - paths: - - 'drivers/**' - - 'lib/arm_atsam/**' - - 'lib/lib8tion/**' - - 'lib/python/**' - - 'platforms/**' - - 'quantum/**' - - 'tests/**' - - 'tmk_core/**' - -jobs: - lint: - runs-on: ubuntu-latest - - container: qmkfm/qmk_cli - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - - name: Install dependencies - run: | - pip3 install -r requirements-dev.txt - - - uses: trilom/file-changes-action@v1.2.4 - id: file_changes - with: - output: ' ' - fileOutput: ' ' - - - name: Run qmk formatters - shell: 'bash {0}' - run: | - cat ~/files_added.txt ~/files_modified.txt > ~/files_changed.txt - qmk format-c --core-only $(< ~/files_changed.txt) || true - qmk format-python $(< ~/files_changed.txt) || true - qmk format-text $(< ~/files_changed.txt) || true - - - name: Fail when formatting required - run: | - git diff - for file in $(git diff --name-only); do - echo "File '${file}' Requires Formatting" - echo "::error file=${file}::Requires Formatting" - done - test -z "$(git diff --name-only)" diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml new file mode 100644 index 0000000000..ba0a86aa78 --- /dev/null +++ b/.github/workflows/format.yml @@ -0,0 +1,51 @@ +name: PR Lint Format + +on: + pull_request: + paths: + - 'drivers/**' + - 'lib/arm_atsam/**' + - 'lib/lib8tion/**' + - 'lib/python/**' + - 'platforms/**' + - 'quantum/**' + - 'tests/**' + - 'tmk_core/**' + +jobs: + lint: + runs-on: ubuntu-latest + + container: qmkfm/qmk_cli + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + pip3 install -r requirements-dev.txt + + - uses: trilom/file-changes-action@v1.2.4 + id: file_changes + with: + output: ' ' + fileOutput: ' ' + + - name: Run qmk formatters + shell: 'bash {0}' + run: | + cat ~/files_added.txt ~/files_modified.txt > ~/files_changed.txt + qmk format-c --core-only $(< ~/files_changed.txt) || true + qmk format-python $(< ~/files_changed.txt) || true + qmk format-text $(< ~/files_changed.txt) || true + + - name: Fail when formatting required + run: | + git diff + for file in $(git diff --name-only); do + echo "File '${file}' Requires Formatting" + echo "::error file=${file}::Requires Formatting" + done + test -z "$(git diff --name-only)" diff --git a/.github/workflows/format_push.yaml b/.github/workflows/format_push.yaml deleted file mode 100644 index 4b51213b36..0000000000 --- a/.github/workflows/format_push.yaml +++ /dev/null @@ -1,49 +0,0 @@ -name: Lint Format - -on: - push: - branches: - - master - - develop - -jobs: - lint: - runs-on: ubuntu-latest - - container: qmkfm/qmk_cli - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - - name: Install dependencies - run: | - pip3 install -r requirements-dev.txt - - - name: Run qmk formatters - shell: 'bash {0}' - run: | - qmk format-c -a - qmk format-python -a - qmk format-text -a - git diff - - - uses: rlespinasse/github-slug-action@v3.x - - - name: Become QMK Bot - run: | - git config user.name 'QMK Bot' - git config user.email 'hello@qmk.fm' - - - name: Create Pull Request - uses: peter-evans/create-pull-request@v3 - if: ${{ github.repository == 'qmk/qmk_firmware'}} - with: - token: ${{ secrets.QMK_BOT_TOKEN }} - delete-branch: true - branch: bugfix/format_${{ env.GITHUB_REF_SLUG }} - author: QMK Bot - committer: QMK Bot - commit-message: Format code according to conventions - title: '[CI] Format code according to conventions' diff --git a/.github/workflows/format_push.yml b/.github/workflows/format_push.yml new file mode 100644 index 0000000000..4b51213b36 --- /dev/null +++ b/.github/workflows/format_push.yml @@ -0,0 +1,49 @@ +name: Lint Format + +on: + push: + branches: + - master + - develop + +jobs: + lint: + runs-on: ubuntu-latest + + container: qmkfm/qmk_cli + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + pip3 install -r requirements-dev.txt + + - name: Run qmk formatters + shell: 'bash {0}' + run: | + qmk format-c -a + qmk format-python -a + qmk format-text -a + git diff + + - uses: rlespinasse/github-slug-action@v3.x + + - name: Become QMK Bot + run: | + git config user.name 'QMK Bot' + git config user.email 'hello@qmk.fm' + + - name: Create Pull Request + uses: peter-evans/create-pull-request@v3 + if: ${{ github.repository == 'qmk/qmk_firmware'}} + with: + token: ${{ secrets.QMK_BOT_TOKEN }} + delete-branch: true + branch: bugfix/format_${{ env.GITHUB_REF_SLUG }} + author: QMK Bot + committer: QMK Bot + commit-message: Format code according to conventions + title: '[CI] Format code according to conventions' -- cgit v1.2.3 From 6822101f9cbdc907d30190753fe336570bab40ba Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sun, 3 Apr 2022 22:01:16 +0100 Subject: Run auto approve only on qmk/qmk_firmware (#16786) --- .github/workflows/auto_approve.yml | 2 ++ 1 file changed, 2 insertions(+) (limited to '.github') diff --git a/.github/workflows/auto_approve.yml b/.github/workflows/auto_approve.yml index 6b986ffccc..dea3f017dd 100644 --- a/.github/workflows/auto_approve.yml +++ b/.github/workflows/auto_approve.yml @@ -8,6 +8,8 @@ jobs: automatic_approve: runs-on: ubuntu-latest + if: github.repository == 'qmk/qmk_firmware' + steps: - uses: mheap/automatic-approve-action@v1 with: -- cgit v1.2.3 From 1f2b1dedccdf21b629c45ece80b4ca32f6653296 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Wed, 13 Apr 2022 18:00:18 +1000 Subject: Quantum Painter (#10174) * Install dependencies before executing unit tests. * Split out UTF-8 decoder. * Fixup python formatting rules. * Add documentation for QGF/QFF and the RLE format used. * Add CLI commands for converting images and fonts. * Add stub rules.mk for QP. * Add stream type. * Add base driver and comms interfaces. * Add support for SPI, SPI+D/C comms drivers. * Include when enabled. * Add base support for SPI+D/C+RST panels, as well as concrete implementation of ST7789. * Add support for GC9A01. * Add support for ILI9341. * Add support for ILI9163. * Add support for SSD1351. * Implement qp_setpixel, including pixdata buffer management. * Implement qp_line. * Implement qp_rect. * Implement qp_circle. * Implement qp_ellipse. * Implement palette interpolation. * Allow for streams to work with either flash or RAM. * Image loading. * Font loading. * QGF palette loading. * Progressive decoder of pixel data supporting Raw+RLE, 1-,2-,4-,8-bpp monochrome and palette-based images. * Image drawing. * Animations. * Font rendering. * Check against 256 colours, dump out the loaded palette if debugging enabled. * Fix build. * AVR is not the intended audience. * `qmk format-c` * Generation fix. * First batch of docs. * More docs and examples. * Review comments. * Public API documentation. --- .github/workflows/unit_test.yml | 2 ++ 1 file changed, 2 insertions(+) (limited to '.github') diff --git a/.github/workflows/unit_test.yml b/.github/workflows/unit_test.yml index 26bcb2f511..726ce19f0c 100644 --- a/.github/workflows/unit_test.yml +++ b/.github/workflows/unit_test.yml @@ -26,5 +26,7 @@ jobs: - uses: actions/checkout@v2 with: submodules: recursive + - name: Install dependencies + run: pip3 install -r requirements-dev.txt - name: Run tests run: make test:all -- cgit v1.2.3 From 6819420b0edbcd242fa404c473e5cc986343ca64 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Tue, 19 Apr 2022 00:46:52 +1000 Subject: Preinstall python dependencies before executing `qmk`. (#16874) --- .github/workflows/develop_api.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/develop_api.yml b/.github/workflows/develop_api.yml index 3eb6e53c20..44d259cfac 100644 --- a/.github/workflows/develop_api.yml +++ b/.github/workflows/develop_api.yml @@ -24,7 +24,9 @@ jobs: persist-credentials: false - name: Generate API Data - run: qmk generate-api + run: | + python3 -m pip install -r requirements-dev.txt + qmk generate-api - name: Upload API Data uses: jakejarvis/s3-sync-action@master -- cgit v1.2.3 From e22a183329fd05d39f88bb9dfebe98cfa7cd8402 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Sun, 29 May 2022 20:15:54 +0100 Subject: Use correct container for unit test workflow (#17242) --- .github/workflows/unit_test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github') diff --git a/.github/workflows/unit_test.yml b/.github/workflows/unit_test.yml index 726ce19f0c..6afe29e04f 100644 --- a/.github/workflows/unit_test.yml +++ b/.github/workflows/unit_test.yml @@ -20,7 +20,7 @@ jobs: test: runs-on: ubuntu-latest - container: qmkfm/base_container + container: qmkfm/qmk_cli steps: - uses: actions/checkout@v2 -- cgit v1.2.3