Add type-safe context accessors for flag values (Set, Get, Lookup) #10
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: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| jobs: | |
| lint: | |
| name: Lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: go.mod | |
| - uses: golangci/golangci-lint-action@v8 | |
| with: | |
| version: latest | |
| test: | |
| name: Test (Go ${{ matrix.go-version }}) | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| go-version: ["stable", "oldstable"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: ${{ matrix.go-version }} | |
| - name: Run tests | |
| run: go test -v -race -coverprofile=coverage.out -covermode=atomic ./... | |
| - name: Upload coverage | |
| if: matrix.go-version == 'stable' | |
| uses: codecov/codecov-action@v5 | |
| with: | |
| files: coverage.out | |
| fail_ci_if_error: false |