diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..e9ffa80 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,35 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + workflow_dispatch: + +permissions: + contents: read + +jobs: + checks: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '22' + - name: Syntaxe JavaScriptu + run: | + for f in $(git ls-files '*.js'); do + node --check "$f" 2>/dev/null || node --input-type=module --check < "$f" + done + - name: Platnost JSON + run: | + for f in $(git ls-files '*.json' '*.webmanifest'); do + python3 -m json.tool "$f" > /dev/null + done + - name: Lokální odkazy + uses: lycheeverse/lychee-action@v2 + with: + args: --offline --include-fragments --no-progress './**/*.html' './**/*.md' + fail: true + failIfEmpty: false