Repository navigation
feat: 解析 Eclipse 服务器运行时和 JUnit 容器,老 Web 项目能跳进 Servlet/JSP/JUnit(0.0.2) #9
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| jobs: | |
| test: | |
| # Linux runs the full suite and packaging; Windows runs the tests once, | |
| # for its paths, file URIs and the read-only extracted JDK copies. | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, windows-latest] | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 15 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| - name: Check formatting | |
| if: runner.os == 'Linux' | |
| run: test -z "$(gofmt -l .)" || { gofmt -l .; exit 1; } | |
| - name: Vet | |
| run: go vet ./... | |
| - name: Test | |
| run: go test -race -count=1 ./... | |
| package: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 10 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - name: Check manifest and build the archives | |
| run: node scripts/package.mjs | |
| - name: Validate against Lithe Store rules | |
| run: | | |
| git clone --depth 1 https://github.com/Lithe-IDEA/Lithe-store "$RUNNER_TEMP/store" | |
| node --input-type=module -e " | |
| import { readPackageManifests, checkManifest } from '$RUNNER_TEMP/store/scripts/validate-index.mjs'; | |
| import { readdirSync, readFileSync } from 'node:fs'; | |
| const manifest = JSON.parse(readFileSync('io.github.lithe-idea.java-navigation/plugin.json', 'utf8')); | |
| const entry = { id: manifest.id }; | |
| let failed = false; | |
| for (const name of readdirSync('dist')) { | |
| const { manifests, unsafe } = readPackageManifests('dist/' + name, entry.id); | |
| const problems = [...unsafe, ...checkManifest(manifests, entry, manifest)]; | |
| for (const problem of problems) { console.error(name + ': ' + problem); failed = true; } | |
| } | |
| process.exit(failed ? 1 : 0); | |
| " |