From b5ab054d74ee15e7910db01f374a2d092ad02289 Mon Sep 17 00:00:00 2001 From: Marc Cataford Date: Sun, 27 Oct 2024 20:34:28 -0400 Subject: [PATCH] ci: run checks on ci --- .forgejo/workflows/ci.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .forgejo/workflows/ci.yml diff --git a/.forgejo/workflows/ci.yml b/.forgejo/workflows/ci.yml new file mode 100644 index 0000000..11d4935 --- /dev/null +++ b/.forgejo/workflows/ci.yml @@ -0,0 +1,26 @@ +on: [push, pull_request] + +jobs: + static-analysis: + runs-on: runner-latest + steps: + - uses: actions/checkout@v4 + - name: Linting + run: pipx run pre-commit run ruff -a + - name: Format + run: pipx run pre-commit run ruff-format -a + - name: Validate Yaml + run: pipx run pre-commit run check-yaml -a + - name: Validate shell scripts + run: pipx run pre-commit run shellcheck -a + export-trace: + runs-on: runner-latest + needs: [static-analysis] + steps: + - uses: https://forge.karnov.club/marc/opentelemetry-trace-export-forgejo-action@main + with: + otlp-endpoint: "http://otel.home.karnov.club:4318" + forgejo-token: ${{ secrets.GITHUB_TOKEN }} + forgejo-base-url: ${{ env.GITHUB_SERVER_URL }} + run-id: ${{ env.GITHUB_RUN_NUMBER }} + repo-name: ${{ env.GITHUB_REPOSITORY }}