Repository navigation
feat(linux): add ARM64 and x64 Java Support Lite packages #14
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, ubuntu-24.04-arm, 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 -timeout=120s -race -count=1 ./... | |
| package: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| arch: x64 | |
| - os: ubuntu-24.04-arm | |
| arch: arm64 | |
| runs-on: ${{ matrix.os }} | |
| 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: Verify Linux release archives | |
| run: node --test --test-timeout=60000 scripts/package/*.test.mjs | |
| - name: Start the packaged Linux language server | |
| run: node scripts/package/smoke-linux.mjs dist/*-linux-${{ matrix.arch }}.zip | |
| - 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); | |
| " |