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

feat: Add ability to go back and modify entry type fields #418

Merged
merged 7 commits into from
Nov 26, 2024

Conversation

c12i
Copy link
Collaborator

@c12i c12i commented Nov 20, 2024

This PR will close #53

@c12i c12i added ShouldBackport/0.3 This change should be backported to develop-0.3 ShouldBackport/0.4 This change should be backported to develop-0.1 labels Nov 20, 2024
@c12i c12i requested a review from a team November 20, 2024 14:54
src/scaffold/entry_type/fields.rs Outdated Show resolved Hide resolved
src/scaffold/entry_type/fields.rs Show resolved Hide resolved
@jost-s
Copy link

jost-s commented Nov 21, 2024

I always get an error that a flake.nix is missing:

$ hc-scaffold example forum
✔ Choose UI framework: (Use arrow-keys. Return to submit) · lit
✔ Choose a package manager: (Use arrow-keys. Return to submit) · npm
Setting up nix development environment...
error: path '/nix/store/90xdfxqppbfn7zk92z0hnjf9j5mfsham-source/forum/flake.nix' does not exist
Error setting up the nix environment

It happens regardless of template and with hello-world too. What is missing?

@c12i
Copy link
Collaborator Author

c12i commented Nov 22, 2024

@jost-s this is strange, I'm unable to reproduce, were you running this inside or outside a nix shell?

@c12i c12i requested a review from cdunster November 22, 2024 11:32
@jost-s
Copy link

jost-s commented Nov 22, 2024

I was running it outside of a nix shell. Now running inside of it, I get the same error:

nix: scaffolding (feat/entry-type-go-back) $ hc-scaffold example hello-world
✔ Choose a package manager: (Use arrow-keys. Return to submit) · npm
Setting up nix development environment...
error: path '/nix/store/90xdfxqppbfn7zk92z0hnjf9j5mfsham-source/hello-world/flake.nix' does not exist
Error setting up the nix environment 

I'll start from scratch again.

@jost-s
Copy link

jost-s commented Nov 22, 2024

I end up at the same error. Here's what I do:

git clone ...
cd scaffolding
cargo install --path .
nix develop
hc-scaffold example hello-world
confirm default npm

@jost-s
Copy link

jost-s commented Nov 25, 2024

@cdunster @matthme I'm testing this on Linux. Can any one of you give this a try as well to compare?

@matthme
Copy link
Collaborator

matthme commented Nov 26, 2024

@jost are you running this inside the scaffolding repo? I think that's the problem. It works fine outside in a separate folder.

@matthme
Copy link
Collaborator

matthme commented Nov 26, 2024

But I can reproduce it if I run it inside the scaffolding repo.

Copy link
Collaborator

@matthme matthme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works for me and looks great!

@jost-s
Copy link

jost-s commented Nov 26, 2024

Right, that's the difference then. I was able to test like this before, I must have done it in a separate folder. Thanks @matthme

@c12i c12i removed the ShouldBackport/0.3 This change should be backported to develop-0.3 label Nov 26, 2024
@c12i c12i merged commit ce996b9 into develop Nov 26, 2024
11 checks passed
@c12i c12i deleted the feat/entry-type-go-back branch November 26, 2024 15:32
c12i added a commit that referenced this pull request Dec 10, 2024
* Add go back functionality for hc scaffold entry-type

* address PR comments

* Ensure the fields vec is not empty on change

* Improve text spacing

* Simplify prompt
@c12i c12i removed the ShouldBackport/0.4 This change should be backported to develop-0.1 label Dec 10, 2024
c12i added a commit that referenced this pull request Dec 12, 2024
* fix: Skip writing scaffold config for nixified custom templates (#415)

* Add skip_config_check global flag to scaffolding

* Prefer not writing the scaffold config for nixified custom templates

* Fix rustfmt warning

* feat: further improve ci runtime (#414)

* Remove dependency to holochain

* Add rust-cache

* Add cachix nix config

* Add ci job concurrency options

* Update cachix configurations

* Run rust checks/tests outside nix

* add missing components

* Cache rust builds

* Bump holochain deps

* Update rustdocs

* Build cargo deps separately

* refactor flake

* Update maintenance docs

* Add extraPullNames input to cachix actions

* Add nix_build step

* Extend extra-substituters and public-keys in nixConfig

* Fix ci workflow

* Bump client-js version

* fix: Fix misplaced doc comments (#411)

* Fix misplaced doc comments

* Slightly refactor link_type integrity codegen

* feat: Enhance custom template generation (#404)

* feat: Add a new template subcommand to create new custom template bases
from existing templates

* Remove call to wrapCustoTemplate in scaffolding nix flake

* Update custom template docs

* chore: update ui dependencies (#407)

* Bump holochain playground

* Update ui core dependencies

* Update lit dependencies

* Fix cli output lines

* Fix broken css import in lit template

* Revert custom-template changes

* Fix vue templates

* Increase testTimeout

* Remove eslint from lit template

* Fix lit CI failure

* Add missing shared styles

* feat: Reprompt user on invalid input (#402)

* Fix imports

* Merge pull request #428 from holochain/fix/svelte-client-race-condition-0.4

chore: backport svelte race condition to 0.4 and release 0.4000.0-rc.1

* feat: Add ability to go back and modify entry type fields (#418)

* Add go back functionality for hc scaffold entry-type

* address PR comments

* Ensure the fields vec is not empty on change

* Improve text spacing

* Simplify prompt

* Pin typescript version for vue-tsc compatibility

---------

Co-authored-by: matthme <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: Add ability to go back when adding entries
4 participants