Skip to content

Commit

Permalink
Merge pull request #44 from strideynet/kevslashnull/sqlc-and-protobuf…
Browse files Browse the repository at this point in the history
…-ci-checks

Add CI jobs to check for sqlc diff
  • Loading branch information
KevSlashNull authored Jul 18, 2023
2 parents 3b7acbb + ccfb7f7 commit 9728fe7
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,26 @@ jobs:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '1.20'
go-version: "1.20"
cache: false
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.53
version: v1.53
check-sqlc:
name: Check sqlc generation
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: "1.20"
cache: false
- name: Install sqlc
run: go install github.com/kyleconroy/sqlc/cmd/[email protected]
- run: sqlc generate
- name: Check that sqlc queries are up-to-date
run: git diff --exit-code
2 changes: 1 addition & 1 deletion docs/developing.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ In addition to this, we’re using `sqlc` and `migrate` to manage our
database schema. Install them by executing the following commands:

```bash
$ go install github.com/kyleconroy/sqlc/cmd/sqlc@latest
$ go install github.com/kyleconroy/sqlc/cmd/sqlc@v1.18.0
$ go install -tags 'postgres' github.com/golang-migrate/migrate/v4/cmd/migrate@latest
```

Expand Down

1 comment on commit 9728fe7

@vercel
Copy link

@vercel vercel bot commented on 9728fe7 Jul 18, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.