feat(sdk+cli): Go SDK, Unix socket IPC, scheduler support, client fixes #6
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: Go SDK | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| paths: | |
| - 'sdk/go/**' | |
| - 'openapi.json' | |
| - '.github/workflows/sdk-go.yml' | |
| pull_request: | |
| branches: [ main, develop ] | |
| paths: | |
| - 'sdk/go/**' | |
| - 'openapi.json' | |
| - '.github/workflows/sdk-go.yml' | |
| schedule: | |
| - cron: '0 2 * * *' | |
| permissions: | |
| contents: read | |
| jobs: | |
| build-and-test: | |
| name: Go SDK Build & Test | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: sdk/go/go.mod | |
| cache-dependency-path: sdk/go/go.sum | |
| - name: Build | |
| working-directory: sdk/go | |
| run: go build ./... | |
| - name: Test | |
| working-directory: sdk/go | |
| run: go test ./... | |
| check-drift: | |
| name: Check Generated Code Drift | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| # Only run drift check when openapi.json changes | |
| if: github.event_name == 'pull_request' | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Set up Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version-file: sdk/go/go.mod | |
| cache-dependency-path: sdk/go/go.sum | |
| - name: Install ogen | |
| run: go install github.com/ogen-go/ogen/cmd/ogen@latest | |
| - name: Regenerate SDK | |
| working-directory: sdk/go | |
| run: go generate ./... | |
| - name: Check for drift | |
| run: | | |
| if ! git diff --exit-code sdk/go/; then | |
| echo "Generated Go SDK code is out of sync with openapi.json." | |
| echo "Run 'cd sdk/go && go generate ./...' and commit the result." | |
| exit 1 | |
| fi |