Skip to content

Commit e5aa717

Browse files
Merge pull request #4 from speakeasy-api/feature/spe-152-sdk
refactor: initial refactor to support new SDK design
2 parents 7e02902 + 61255dc commit e5aa717

23 files changed

+835
-1226
lines changed

.github/workflows/lint.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: lint
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
env:
9+
GOPRIVATE: "github.com/speakeasy-api"
10+
jobs:
11+
golangci:
12+
name: lint
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/setup-go@v3
16+
with:
17+
go-version: 1.14
18+
19+
- name: Configure git for private modules
20+
env:
21+
GIT_AUTH_TOKEN: ${{ secrets.BOT_REPO_TOKEN }}
22+
run: git config --global url."https://speakeasybot:${GIT_AUTH_TOKEN}@github.com".insteadOf "https://github.com"
23+
24+
- uses: actions/checkout@v3
25+
- name: golangci-lint
26+
uses: golangci/golangci-lint-action@v3
27+
with:
28+
# Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
29+
version: latest

.github/workflows/tests.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ name: Tests
22

33
on:
44
push:
5+
branches:
6+
- main
57
pull_request:
68
env:
79
GOPRIVATE: "github.com/speakeasy-api"
@@ -12,7 +14,7 @@ jobs:
1214
strategy:
1315
fail-fast: true
1416
matrix:
15-
go-version: [ 1.14.x, 1.15.x, 1.16.x, 1.17.x, 1.18.x ]
17+
go-version: [1.14.x, 1.15.x, 1.16.x, 1.17.x, 1.18.x]
1618

1719
name: Tests - Go ${{ matrix.go-version }}
1820

@@ -21,7 +23,7 @@ jobs:
2123
env:
2224
GIT_AUTH_TOKEN: ${{ secrets.BOT_REPO_TOKEN }}
2325
run: git config --global url."https://speakeasybot:${GIT_AUTH_TOKEN}@github.com".insteadOf "https://github.com"
24-
26+
2527
- name: Checkout the code
2628
uses: actions/checkout@v2
2729

.golangci.yaml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
linters:
2+
enable-all: true
3+
disable:
4+
- lll
5+
- varnamelen
6+
- exhaustivestruct
7+
- exhaustruct
8+
- godox
9+
- nlreturn
10+
- wsl
11+
- wrapcheck
12+
- gochecknoglobals
13+
- paralleltest
14+
- dupl
15+
- containedctx
16+
# Deprecated
17+
- golint
18+
- maligned
19+
- interfacer
20+
- scopelint
21+
issues:
22+
exclude:
23+
- "returns unexported type"
24+
- "unlambda"
25+
- "should rewrite http.NewRequestWithContext"
26+
exclude-rules:
27+
# Exclude some linters from running on tests files.
28+
- path: _test\.go
29+
linters:
30+
- scopelint
31+
- goerr113
32+
- funlen
33+
- gocognit
34+
- cyclop
35+
- path: _exports_test\.go
36+
linters:
37+
- testpackage
38+
include:
39+
- EXC0012
40+
- EXC0013
41+
- EXC0014
42+
- EXC0015
43+
run:
44+
go: "1.14"

configuration.go

Lines changed: 0 additions & 155 deletions
This file was deleted.

go.mod

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,17 @@
11
module github.com/speakeasy-api/speakeasy-go-sdk
22

3-
go 1.17
3+
go 1.14
44

55
require (
6-
github.com/go-chi/chi v1.5.4
6+
github.com/chromedp/cdproto v0.0.0-20220629234738-4cfc9cdeeb92
77
github.com/stretchr/testify v1.7.5
88
)
99

10-
require (
11-
github.com/go-openapi/jsonpointer v0.19.5 // indirect
12-
github.com/go-openapi/swag v0.19.5 // indirect
13-
github.com/gorilla/mux v1.8.0 // indirect
14-
github.com/invopop/yaml v0.1.0 // indirect
15-
github.com/jinzhu/inflection v1.0.0 // indirect
16-
github.com/jinzhu/now v1.1.4 // indirect
17-
github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e // indirect
18-
github.com/speakeasy-api/speakeasy-schemas v0.0.0-20220706203759-a102a61fdb5f // indirect
19-
go.uber.org/atomic v1.7.0 // indirect
20-
go.uber.org/multierr v1.6.0 // indirect
21-
gopkg.in/yaml.v2 v2.4.0 // indirect
22-
)
10+
require gopkg.in/yaml.v2 v2.4.0 // indirect
2311

2412
require (
25-
github.com/SamuelTissot/sqltime v0.1.0
26-
github.com/davecgh/go-spew v1.1.1 // indirect
27-
github.com/getkin/kin-openapi v0.97.0
28-
github.com/google/uuid v1.3.0
29-
github.com/jinzhu/copier v0.3.5
30-
github.com/pmezard/go-difflib v1.0.0 // indirect
13+
github.com/speakeasy-api/speakeasy-schemas v0.0.0-20220714165541-1cb067bd97e6
3114
go.uber.org/zap v1.21.0
32-
gopkg.in/yaml.v3 v3.0.1 // indirect
33-
gorm.io/gorm v1.23.6
15+
google.golang.org/grpc v1.48.0
16+
google.golang.org/protobuf v1.28.0 // indirect
3417
)

0 commit comments

Comments
 (0)