From 4ef0afe8e5102fc7290b9d680b0f429f1c586bb9 Mon Sep 17 00:00:00 2001 From: Username Date: Sun, 18 Jan 2026 17:14:37 +0100 Subject: [PATCH] ci: add lint and syntax check workflow --- .gitea/workflows/ci.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .gitea/workflows/ci.yml diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml new file mode 100644 index 0000000..1707abe --- /dev/null +++ b/.gitea/workflows/ci.yml @@ -0,0 +1,27 @@ +name: CI + +on: + push: + branches: [master] + pull_request: + branches: [master] + +jobs: + lint: + runs-on: linux_amd64 + container: + image: python:3.11-slim + steps: + - name: Checkout + run: | + git clone --depth 1 --branch "${GITHUB_REF_NAME}" \ + "https://oauth2:${{ github.token }}@${GITHUB_SERVER_URL#https://}/${GITHUB_REPOSITORY}.git" . + + - name: Install tools + run: pip install --quiet ruff + + - name: Syntax check + run: python -m py_compile harbor-ctl.py + + - name: Lint + run: ruff check --select=E,F,W harbor-ctl.py