ci: add workflow_dispatch trigger to test.yml #2
This file contains hidden or 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: Test | |
| on: | |
| push: | |
| paths: | |
| - "src/**" | |
| - "tests/**" | |
| - ".github/workflows/test.yml" | |
| pull_request: | |
| paths: | |
| - "src/**" | |
| - "tests/**" | |
| - ".github/workflows/test.yml" | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - lua-version: "5.1" | |
| - lua-version: "5.2" | |
| - lua-version: "5.3" | |
| - lua-version: "5.4" | |
| - lua-version: "5.5" | |
| - lua-version: "luajit" | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: leafo/gh-actions-lua@v13 | |
| with: | |
| luaVersion: ${{ matrix.lua-version }} | |
| - uses: leafo/gh-actions-luarocks@v6 | |
| - name: Build | |
| run: luarocks make rockspecs/bluelua-evdev-scm-1.rockspec | |
| - name: Install busted | |
| run: | | |
| luarocks install busted | |
| echo "$HOME/.luarocks/bin" >> "$GITHUB_PATH" | |
| - name: Prepare uinput | |
| run: | | |
| echo 'KERNEL=="event*", SUBSYSTEM=="input", MODE="0666"' | sudo tee /etc/udev/rules.d/99-evdev-test.rules | |
| sudo udevadm control --reload-rules | |
| sudo modprobe uinput || true | |
| sudo udevadm trigger --subsystem-match=input || true | |
| test -e /dev/uinput | |
| sudo chmod 666 /dev/uinput | |
| - name: Test | |
| run: busted |