Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ module github.com/ViRb3/wgcf/v2
go 1.26.0

require (
github.com/ViRb3/wgcf/v2/openapi v0.0.0-00010101000000-000000000000
github.com/cockroachdb/errors v1.14.0
github.com/dustin/go-humanize v1.1.0
github.com/manifoldco/promptui v0.9.0
github.com/refraction-networking/utls v1.8.2
github.com/spf13/cobra v1.10.2
github.com/spf13/viper v1.21.0
github.com/stretchr/testify v1.11.1
golang.org/x/crypto v0.57.0
)

Expand All @@ -18,6 +18,7 @@ require (
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e // indirect
github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect
github.com/cockroachdb/redact v1.1.5 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/fsnotify/fsnotify v1.9.0 // indirect
github.com/getsentry/sentry-go v0.46.0 // indirect
github.com/go-viper/mapstructure/v2 v2.4.0 // indirect
Expand All @@ -28,6 +29,7 @@ require (
github.com/kr/text v0.2.0 // indirect
github.com/pelletier/go-toml/v2 v2.2.4 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/rogpeppe/go-internal v1.12.0 // indirect
github.com/sagikazarmark/locafero v0.11.0 // indirect
github.com/sourcegraph/conc v0.3.1-0.20240121214520-5f936abd7ae8 // indirect
Expand All @@ -38,6 +40,5 @@ require (
go.yaml.in/yaml/v3 v3.0.4 // indirect
golang.org/x/sys v0.48.0 // indirect
golang.org/x/text v0.42.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)

replace github.com/ViRb3/wgcf/v2/openapi => ./openapi
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//go:generate openapi-generator generate -i openapi-spec.yml -g go -o openapi --additional-properties=disallowAdditionalPropertiesIfNotPresent=false
//go:generate openapi-generator generate -i openapi-spec.yml -g go -o openapi --git-user-id ViRb3 --git-repo-id wgcf/v2 --additional-properties=disallowAdditionalPropertiesIfNotPresent=false,withGoMod=false,isGoSubmodule=true

package main

Expand Down
4 changes: 2 additions & 2 deletions openapi/.openapi-generator/FILES
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.gitignore
.openapi-generator-ignore
.travis.yml
README.md
api/openapi.yaml
Expand Down Expand Up @@ -49,8 +50,6 @@ docs/UpdateAccountRequest.md
docs/UpdateBoundDeviceRequest.md
docs/UpdateSourceDeviceRequest.md
git_push.sh
go.mod
go.sum
model_account.go
model_alternate_network.go
model_app_mode.go
Expand Down Expand Up @@ -94,4 +93,5 @@ model_update_account_request.go
model_update_bound_device_request.go
model_update_source_device_request.go
response.go
test/api_default_test.go
utils.go
2 changes: 1 addition & 1 deletion openapi/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ go get golang.org/x/net/context
Put the package under your project folder and add the following in import:

```go
import openapi "github.com/GIT_USER_ID/GIT_REPO_ID"
import openapi "github.com/ViRb3/wgcf/v2/openapi"
```

To use a proxy, set the environment variable `HTTP_PROXY`:
Expand Down
28 changes: 14 additions & 14 deletions openapi/docs/DefaultApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -107,7 +107,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -181,7 +181,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -250,7 +250,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -321,7 +321,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -392,7 +392,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -460,7 +460,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -534,7 +534,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -607,7 +607,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -679,7 +679,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -750,7 +750,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -823,7 +823,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -899,7 +899,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down Expand Up @@ -970,7 +970,7 @@ import (
"context"
"fmt"
"os"
openapiclient "github.com/GIT_USER_ID/GIT_REPO_ID"
openapiclient "github.com/ViRb3/wgcf/v2/openapi"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions openapi/git_push.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ if [ "$git_host" = "" ]; then
fi

if [ "$git_user_id" = "" ]; then
git_user_id="GIT_USER_ID"
git_user_id="ViRb3"
echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
fi

if [ "$git_repo_id" = "" ]; then
git_repo_id="GIT_REPO_ID"
git_repo_id="wgcf/v2"
echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
fi

Expand Down
6 changes: 0 additions & 6 deletions openapi/go.mod

This file was deleted.

11 changes: 0 additions & 11 deletions openapi/go.sum

This file was deleted.

76 changes: 75 additions & 1 deletion openapi/test/api_default_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.