fix: safely construct bash file completions (#110) #522
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 | |
| permissions: {} | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| merge_group: | |
| types: | |
| - checks_requested | |
| jobs: | |
| lint: | |
| timeout-minutes: 10 | |
| name: lint | |
| permissions: | |
| contents: read | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| with: | |
| persist-credentials: false | |
| - uses: ./.github/actions/setup-go | |
| - name: Run lints | |
| run: ./scripts/lint | |
| build-artifacts: | |
| timeout-minutes: 10 | |
| name: build artifacts | |
| permissions: | |
| contents: read | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| with: | |
| persist-credentials: false | |
| - uses: ./.github/actions/setup-go | |
| - name: Test vulnerability scan coverage | |
| run: ./scripts/govulncheck-test | |
| - name: Check shipped CLI for reachable vulnerabilities | |
| run: ./scripts/govulncheck | |
| - name: Test verified GoReleaser installer | |
| run: ./scripts/test-goreleaser-installer | |
| - name: Set up verified GoReleaser | |
| id: goreleaser | |
| uses: ./.github/actions/setup-goreleaser | |
| - name: Run GoReleaser | |
| run: | | |
| "$GORELEASER_EXECUTABLE" release --snapshot --clean --skip=publish | |
| env: | |
| GORELEASER_EXECUTABLE: ${{ steps.goreleaser.outputs.executable }} | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| build: | |
| timeout-minutes: 10 | |
| name: build | |
| needs: | |
| - build-artifacts | |
| if: always() | |
| permissions: {} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Require successful build | |
| env: | |
| BUILD_RESULT: ${{ needs.build-artifacts.result }} | |
| run: | | |
| if [[ "$BUILD_RESULT" != "success" ]]; then | |
| echo "Build artifacts failed: $BUILD_RESULT" | |
| exit 1 | |
| fi | |
| test: | |
| timeout-minutes: 10 | |
| name: test | |
| permissions: | |
| contents: read | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| with: | |
| persist-credentials: false | |
| - uses: ./.github/actions/setup-go | |
| - name: Run tests | |
| run: ./scripts/test |