ci: add standard CI workflow
Some checks failed
CI / lint (push) Has been cancelled
Security Scan / scan (push) Has been cancelled

This commit is contained in:
2026-03-16 12:24:01 -05:00
parent 48d10bf070
commit c19878fed7

24
.gitea/workflows/ci.yml Normal file
View File

@@ -0,0 +1,24 @@
name: CI
on: [push, pull_request]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Detect and lint
run: |
if [ -f package.json ]; then
npm ci --ignore-scripts 2>/dev/null || npm install --ignore-scripts
npx eslint . --ext .js,.ts,.jsx,.tsx --no-error-on-unmatched-pattern 2>/dev/null || true
fi
if [ -f requirements.txt ] || [ -f setup.py ] || [ -f pyproject.toml ]; then
pip install ruff 2>/dev/null
ruff check . 2>/dev/null || true
fi
if ls *.sh 2>/dev/null || ls **/*.sh 2>/dev/null; then
shellcheck *.sh **/*.sh 2>/dev/null || true
fi
- name: Check syntax
run: |
find . -name "*.py" -exec python3 -c "import py_compile; py_compile.compile('{}', doraise=True)" \; 2>/dev/null || true
find . -name "*.sh" -exec bash -n {} \; 2>/dev/null || true