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

Sandbox creation #536

Merged
merged 8 commits into from
Aug 30, 2021
Merged

Sandbox creation #536

merged 8 commits into from
Aug 30, 2021

Conversation

miketalley
Copy link
Contributor

@miketalley miketalley commented Aug 13, 2021

Description and Context

Adds hs sandbox create [name] command. Name can be provided to the command as a positional argument or the user will be prompted if no name is specified.

Screenshots

This is now hs sandbox create
image

image

Additional Fixes

  • Fixes "Cannot read property 'name' of undefined" error when running hs auth with an invalid personal access key

image

Screenshots

Who to Notify

@kimunz @cbaldauf @fndicu @gcornelius @mhazlewood @brodgers

…ing in Cannot read property 'name' of undefined
@miketalley miketalley changed the title fixed continuation of code running when invalid PAK is entered result… Sandbox creation Aug 13, 2021
@gcorne
Copy link
Contributor

gcorne commented Aug 19, 2021

One thing that I am not super comfortable with adding hs create sandbox is that this breaks the existing semantics of hs create. All of the various subcommands of hs create create things on the user's local computer — either single files or more complex things like a theme from the theme boilerplate. This command is very different in that it makes a change to a user's HubSpot account.

@miketalley miketalley marked this pull request as ready for review August 20, 2021 18:46
@brandenrodgers
Copy link
Contributor

All of the various subcommands of hs create create things on the user's local computer

I hadn't thought of it until you mentioned it, but that's a good call out. The current mental model of the "create" command is that it generates the boilerplate files for certain assets. It is a much different pattern to be using it to initialize a new HubSpot sandbox account. This probably isn't the greatest suggestion, but creating and connecting the CLI to a sandbox account feels like an action that is closer to what hs init currently does.

@miketalley
Copy link
Contributor Author

I've changed this command to be hs sandbox create as that seems to fit better with the current pattern of commands.

@miketalley miketalley merged commit 1a6e0cc into master Aug 30, 2021
@miketalley miketalley deleted the sandbox/create-command branch August 30, 2021 14:48
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.

3 participants