ci: dupe placeholder workflow for push, add workflow_dispatch
All checks were successful
/ static-analysis (pull_request) Successful in 1m16s
/ tests (pull_request) Successful in 1m15s
/ export-trace (pull_request) Successful in 28s
/ static-analysis (push) Successful in 1m21s
/ tests (push) Successful in 1m19s
/ export-trace (push) Successful in 27s
All checks were successful
/ static-analysis (pull_request) Successful in 1m16s
/ tests (pull_request) Successful in 1m15s
/ export-trace (pull_request) Successful in 28s
/ static-analysis (push) Successful in 1m21s
/ tests (push) Successful in 1m19s
/ export-trace (push) Successful in 27s
This commit is contained in:
parent
b141c7b3bb
commit
d420b1dbbe
2 changed files with 42 additions and 1 deletions
|
@ -1,4 +1,6 @@
|
||||||
on: [pull_request]
|
on:
|
||||||
|
pull_request:
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
static-analysis:
|
static-analysis:
|
||||||
|
|
39
.forgejo/workflows/push.yml
Normal file
39
.forgejo/workflows/push.yml
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
push:
|
||||||
|
branches: [main]
|
||||||
|
|
||||||
|
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
|
||||||
|
tests:
|
||||||
|
runs-on: runner-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: https://github.com/astral-sh/setup-uv@v3
|
||||||
|
- name: Tests
|
||||||
|
run: |
|
||||||
|
uv venv
|
||||||
|
uv pip install .
|
||||||
|
pipx run pre-commit run pytest -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 }}
|
Loading…
Reference in a new issue