diff --git a/cmd/spawn/new_chain.go b/cmd/spawn/new_chain.go index d7688896..9a1db851 100644 --- a/cmd/spawn/new_chain.go +++ b/cmd/spawn/new_chain.go @@ -29,8 +29,8 @@ var ( {ID: "ibc-ratelimit", IsSelected: false, Details: "Thresholds for outflow as a percent of total channel value"}, {ID: "cosmwasm", IsSelected: false, Details: "Cosmos smart contracts"}, {ID: "wasm-light-client", IsSelected: false, Details: "08 Wasm Light Client"}, - {ID: "optimistic-execution", IsSelected: false, Details: "Pre-process blocks ahead of consensus request"}, - {ID: "block-explorer", IsSelected: true, Details: "Ping Pub Explorer"}, + {ID: "optimistic-execution", IsSelected: true, Details: "Pre-process blocks ahead of consensus request"}, + {ID: "block-explorer", IsSelected: false, Details: "Ping Pub Explorer"}, }...) // parentDeps is a list of modules that are disabled if a parent module is disabled. diff --git a/simapp/.gitignore b/simapp/.gitignore index 7b0463fd..b75e1c38 100644 --- a/simapp/.gitignore +++ b/simapp/.gitignore @@ -1,3 +1,6 @@ # Built with https://github.com/rollchains/spawn configs/logs.json -dist/ \ No newline at end of file +dist/ + +# Create cosmos app +web/ diff --git a/simapp/Makefile b/simapp/Makefile index 1d207ba9..39bba614 100644 --- a/simapp/Makefile +++ b/simapp/Makefile @@ -317,6 +317,11 @@ sh-testnet: mod-tidy explorer: docker compose up +.PHONY: generate-webapp +generate-webapp: + sudo npm install --global create-cosmos-app + cca --name web -e spawn + help: @echo "Usage: make " @echo "" @@ -328,5 +333,6 @@ help: @echo " sh-testnet : Shell local devnet" @echo " ictest-basic : Basic end-to-end test" @echo " ictest-ibc : IBC end-to-end test" + @echo " generate-webapp : Create a new webapp template" .PHONY: help diff --git a/simapp/README.md b/simapp/README.md index 000def88..d38402c3 100644 --- a/simapp/README.md +++ b/simapp/README.md @@ -6,12 +6,14 @@ ## Content Generation -- `make proto-gen` *Generates golang code from proto files, stubs interfaces* +- `make proto-gen` *Generates go code from proto files, stubs interfaces* ## Testnet - `make testnet` *IBC testnet from chain <-> local cosmos-hub* - `make sh-testnet` *Single node, no IBC. quick iteration* +- `local-ic chains` *See available testnets from the chains/ directory* +- `local-ic start ` *Starts a local chain with the given name* ## Local Images @@ -22,3 +24,11 @@ - `go test ./... -v` *Unit test* - `make ictest-*` *E2E testing* + +## Webapp Template + +Generate the template base with spawn. Requires [npm](https://nodejs.org/en/download/package-manager) and [yarn](https://classic.yarnpkg.com/lang/en/docs/install) to be installed. + +- `make generate-webapp` *[Cosmology Webapp Template](https://github.com/cosmology-tech/create-cosmos-app)* + +Start the testnet with `make testnet`, and open the webapp `cd ./web && yarn dev` diff --git a/spawn/cfg.go b/spawn/cfg.go index 42ae3989..3afb1ccc 100644 --- a/spawn/cfg.go +++ b/spawn/cfg.go @@ -160,6 +160,7 @@ func (cfg *NewChainConfig) AnnounceSuccessfulBuild() { fmt.Printf(" - $ gh repo create %s --source=. --remote=upstream --push --private\n", projName) fmt.Println(" - $ spawn module new # generate a new module scaffolding") fmt.Println(" - $ make testnet # build & start a testnet with IBC") + fmt.Println(" - $ make generate-webapp # create cosmos webapp template") } func (cfg *NewChainConfig) GithubPath() string {