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

Adding File Management #138

Merged
merged 28 commits into from
Dec 9, 2022
Merged

Adding File Management #138

merged 28 commits into from
Dec 9, 2022

Conversation

miketalley
Copy link
Contributor

@miketalley miketalley commented Nov 21, 2022

Description

Adds Quick Links and Tools sections. Allows installation and updating of @hubspot/cli through buttons.

Features

  • Adds Tools section as viewsWelcome
    • Checks for availability of npm (which npm)
    • Checks for availability of @hubspot/cli (which hs)
      • Checks version of CLI if installed
      • Checks latest version of CLI if installed
    • If CLI is not installed adds Install CLI button that will run npm i -g @hubspot/cli@latest in terminal and show information popup when complete
    • If CLI is installed, but there is a newer version, adds a Update CLI button that will run npm i -g @hubspot/cli@latest in terminal and show information popup when complete
  • Adds Quick Links treedata section with links to commands
    • Upload
    • Fetch
    • Watch
    • Remove

Demo

https://www.loom.com/share/e252eeb818ff404b817480e81c934863

/cc @hs-cboamah @TanyaScales @anthmatic @jsines

src/lib/commands.ts Outdated Show resolved Hide resolved
}
});
terminal.sendText("echo 'Installing the HubSpot CLI.'");
terminal.sendText('npm i -g @hubspot/cli@latest');
Copy link

Choose a reason for hiding this comment

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

Should we allow them to specify npm / yarn / other ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Do you think that multiple buttons would be the way to go, or have a quickpick open up when clicking the button 🤔

Multiple buttons
image

Quickpick
image

Copy link
Member

@TanyaScales TanyaScales Dec 5, 2022

Choose a reason for hiding this comment

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

Interestingly, Stripe (which is where the thought for this functionality originated from) sends the user to the documentation to install from various providers -- perhaps we could do a combination here where the main Install button that you have is npm (we can call this out with text around the button) and we can add a link below to send to documentation about installing the CLI for other providers

The docs screen that Stripe sends its users to
Screen Shot 2022-12-05 at 12 43 35 PM

Copy link
Contributor Author

@miketalley miketalley Dec 5, 2022

Choose a reason for hiding this comment

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

Yeah I did see that Stripe was sending folks to the docs instead of doing the installation. I was going by the description of the issue -> https://git.hubteam.com/HubSpot/cms-developer-tooling/issues/54 and discussion with @hs-cboamah to create the button.

There is a link above the button that leads to https://developers.hubspot.com/docs/cms/developer-reference/local-development-cli. Here is the text with the button under it...

image

Should we change the text, or do we want to change the flow of this to be a link to the docs for installation? I think it works well with the link to the docs and button for easy install. 🤷

Copy link
Member

Choose a reason for hiding this comment

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

I think keeping the button is totally fine -- let's just adjust the text around the installation button.

"In order to use additional features that are not currently available within the HubSpot VS Code extension, you can install the HubSpot CLI (via npm) using the button below. To see other available installation options, check out the documentation."

We'll have to follow up with additions/changes/updates to the docs in order to support this. Probably a CMS Developer Doc page dedicated to the extension would help. Otherwise, in the interim, we can create some quick documentation that lives in the readme of the repo for CLI (or extension) in order to send devs to.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated!

What kind of info do you see this doc containing?

@miketalley miketalley changed the base branch from auth-changes to mike-testing November 29, 2022 20:48
@miketalley miketalley marked this pull request as ready for review December 5, 2022 16:46
@miketalley miketalley mentioned this pull request Dec 5, 2022
@miketalley miketalley changed the base branch from mike-testing to v1.0.0 December 5, 2022 17:26
@TanyaScales
Copy link
Member

For the quick links (based on the demo you gave earlier today):

IMO, the links you have in the Quick Links section should point to the Interacting with the Developer File System (CLI) page of the CMS docs -- and that section should be titled Help & Feedback. Since we are going to already be building out this section with some other doc links and such.

--

For the CLI section -- currently the title there is Tools -- do we foresee other "tools" being housed under this area?

Copy link
Contributor

@jsines jsines left a comment

Choose a reason for hiding this comment

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

Everything else LGTM! 🔥

@miketalley
Copy link
Contributor Author

For the quick links (based on the demo you gave earlier today):

IMO, the links you have in the Quick Links section should point to the Interacting with the Developer File System (CLI) page of the CMS docs -- and that section should be titled Help & Feedback. Since we are going to already be building out this section with some other doc links and such.

--

For the CLI section -- currently the title there is Tools -- do we foresee other "tools" being housed under this area?

I was setting up the Quick Links and Tools sections based on a conversation with @hs-cboamah. As I understand it, we will add other items to the Tools section at a later date.

As for the Quick Links section and Help & Feedback section. Are these meant to be the same section @hs-cboamah ?

@miketalley miketalley merged commit 042d403 into v1.0.0 Dec 9, 2022
@TanyaScales TanyaScales deleted the file-management branch July 14, 2023 19:24
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.

4 participants