Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(cca): fix dropdrown and improve msg #160

Merged
merged 1 commit into from
Jan 23, 2025
Merged
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
2 changes: 1 addition & 1 deletion cca/cmd/scaffold.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,5 @@ func ExecuteScaffold(ctx context.Context, cmd *plugin.ExecutedCommand) error {
return fmt.Errorf("failed to write CCA: %w", err)
}

return session.Printf("🎉 Ignite CCA added (`%[1]v`).\n", c.AppPath(), c.Name())
return session.Printf("🎉 Ignite CCA added (`%[1]v/web`).\n", c.AppPath(), c.Name())
}
8 changes: 4 additions & 4 deletions cca/templates/README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# Templates

The template is based on Cosmology's [chain-admin template](https://github.com/cosmology-tech/create-cosmos-app/tree/fd87039feee9568a86aa8d8d19edea8f4a78f599/templates/chain-template) at commit `fd87039feee9568a86aa8d8d19edea8f4a78f599`.
The template is based on Cosmology's [chain-template](https://github.com/cosmology-tech/create-cosmos-app/tree/fd87039feee9568a86aa8d8d19edea8f4a78f599/templates/chain-template) at commit `fd87039feee9568a86aa8d8d19edea8f4a78f599`.

Some modifications have been done to make it work nicer with Ignite scaffolded chains.
An exhaustive list of changes compared to the original template can be found [here](./ignite-chain-admin.patch).
An exhaustive list of changes compared to the original template can be found [here](./ignite-chain-template.patch).

## Development Instructions

When upgrading the templates:

- checkout `github.com/cosmology-tech/create-cosmos-app` at the above mentioned commit.
- apply the git patch to the `chain-template` directory (`git apply ignite-chain-admin.patch`)
- apply the git patch to the `chain-template` directory (`git apply ignite-chain-template.patch`)
- merge upstream changes from main
- commit the changes (as a single commit, rewriting history if necessary -- `git reset $(git merge-base main $(git branch --show-current))`)
- export the changes to a patch file (`git diff main > ignite-chain-admin.patch`)
- export the changes to a patch file (`git diff main > ignite-chain-template.patch`)
Original file line number Diff line number Diff line change
Expand Up @@ -2647,6 +2647,20 @@ index aae05fd1..57e3c1ea 100644
if (proposal.status === ProposalStatus.PROPOSAL_STATUS_VOTING_PERIOD) {
(async () => {
for (const { address } of chain?.apis?.rest || []) {
diff --git a/templates/chain-template/next.config.js b/templates/chain-template/next.config.js
index 59bb75ea..f3cafd6d 100644
--- a/templates/chain-template/next.config.js
+++ b/templates/chain-template/next.config.js
@@ -16,6 +16,9 @@ module.exports = {
{
hostname: 'raw.githubusercontent.com',
},
+ {
+ hostname: 'ignite.com',
+ },
],
},
};
diff --git a/templates/chain-template/package.json b/templates/chain-template/package.json
index 3d285bd8..b4f20c68 100644
--- a/templates/chain-template/package.json
Expand Down
3 changes: 3 additions & 0 deletions cca/templates/web/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ module.exports = {
{
hostname: 'raw.githubusercontent.com',
},
{
hostname: 'ignite.com',
}
],
},
};
Loading