Skip to content

Commit

Permalink
[DFI-753] migrate swagger to dfinance cosmos-sdk version (#218)
Browse files Browse the repository at this point in the history
* [DFI-753] migrate swagger to dfinance cosmos-sdk version

* Cosmos SDK version bump, Swagger update

* go mod tidy

Co-authored-by: Mikhail Kornilov <[email protected]>
(cherry picked from commit c7eaa78)
  • Loading branch information
g3co authored and Mikhail Kornilov committed Oct 13, 2020
1 parent fa06394 commit 3cd4f7a
Show file tree
Hide file tree
Showing 4 changed files with 2,032 additions and 594 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ cosmos_dir=$(swagger_dir)/cosmos-sdk
dnode = ./cmd/dnode
dncli =./cmd/dncli

cosmos_version = v0.39.1
cosmos_version = dfinance/launchpad

all: install
install: go.sum install-dnode install-dncli
Expand Down Expand Up @@ -58,7 +58,7 @@ swagger-ui-deps:
mkdir -p $(cosmos_dir)

@echo "-> Cosmos-SDK $(cosmos_version) checkout"
git -C $(swagger_dir) clone --branch $(cosmos_version) https://github.com/cosmos/cosmos-sdk.git
git -C $(swagger_dir) clone --branch $(cosmos_version) https://github.com/dfinance/cosmos-sdk.git

@echo "-> Fetching Golang libraries: swag, statik"
go get -u github.com/swaggo/swag/cmd/swag
Expand All @@ -71,7 +71,7 @@ swagger-ui-build:
swag init --dir . --output $(swagger_dir) --generalInfo ./cmd/dnode/main.go --parseDependency

@echo "-> Merging swagger files"
go-swagger-merger -o ./cmd/dncli/docs/swagger.yaml $(swagger_dir)/swagger.yaml $(cosmos_dir)/client/lcd/swagger-ui/swagger.yaml
go-swagger-merger -o ./cmd/dncli/docs/swagger.yaml $(swagger_dir)/swagger.yaml $(cosmos_dir)/client/lcd/swagger-auto/swagger.yaml

@echo "-> Building swagger.go file"
echo "// Code generated by Makefile. DO NOT EDIT.\n" > ./cmd/dncli/docs/swagger.go
Expand Down
Loading

0 comments on commit 3cd4f7a

Please sign in to comment.