diff --git a/.forgejo/workflows/build.yml b/.forgejo/workflows/build.yml deleted file mode 100644 index 3e3ec220..00000000 --- a/.forgejo/workflows/build.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: build bin - -on: - push: - branches: [main] - pull_request: - branches: [main] - -permissions: - contents: read - -jobs: - build: - name: Make sure build does not fail - runs-on: ubuntu-latest - steps: - - uses: https://code.forgejo.org/actions/checkout@v4 - name: checkout - - name: install alsa devel - run: apt update && apt install libasound2-dev -y - - uses: https://code.forgejo.org/actions/setup-go@v5 - name: install go - with: - go-version-file: './go.mod' - - run: go version - name: Go version - - run: make dep - name: install dependencies - - run: make build - name: build app - diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml new file mode 100644 index 00000000..30415134 --- /dev/null +++ b/.forgejo/workflows/ci.yml @@ -0,0 +1,61 @@ +name: ci/ci + +on: + push: + branches: [main] + pull_request: + branches: [main] + +permissions: + contents: read + +jobs: + codespell: + name: Check for spelling errors + runs-on: ubuntu-latest + steps: + - name: ERROR OUT + run: exit 1 + - name: Checkout + uses: actions/checkout@v4 + - name: Annotate locations with typos + uses: "https://github.com/codespell-project/codespell-problem-matcher@v1" + - name: Codespell + uses: "https://github.com/codespell-project/actions-codespell@v2" + with: + check_filenames: true + check_hidden: true + skip: ./.git + + compile: + name: Make sure build does not fail + runs-on: ubuntu-latest + steps: + - uses: https://code.forgejo.org/actions/checkout@v4 + name: checkout + - name: install alsa devel + run: apt update && apt install libasound2-dev -y + - uses: https://code.forgejo.org/actions/setup-go@v5 + name: install go + with: + go-version-file: './go.mod' + - run: go version + name: Go version + - run: make dep + name: install dependencies + - run: make build + name: build app + + notify-fail: + name: notify-fail + runs-on: ubuntu-latest + if: ${{ always() && contains(needs.*.result, 'failure') }} + steps: + - name: gotify + run: curl "${{ secrets.GOTIFY_SERVER_URL }}?token=${{ secrets.GOTIFY_TOKEN }}" \ + -F "title='CI failed'" \ + -F "message='Something failed @ ${{ env.GITHUB_REPOSITORY }}'" \ + -F "priority=7" &> /dev/null + + + diff --git a/.forgejo/workflows/codespell.yml b/.forgejo/workflows/codespell.yml deleted file mode 100644 index 337a3d27..00000000 --- a/.forgejo/workflows/codespell.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: Codespell - -on: - push: - branches: [main] - pull_request: - branches: [main] - -permissions: - contents: read - -jobs: - codespell: - name: Check for spelling errors - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Annotate locations with typos - uses: "https://github.com/codespell-project/codespell-problem-matcher@v1" - - name: Codespell - uses: "https://github.com/codespell-project/actions-codespell@v2" - with: - check_filenames: true - check_hidden: true - skip: ./.git