HubSpot / hubspot-cli

A CLI for HubSpot
https://developers.hubspot.com
Other
153 stars 57 forks source link

Exit local dev earlier for projects without components #1160

Closed camden11 closed 2 weeks ago

camden11 commented 2 weeks ago

Description and Context

You can't run local dev if your project doesn't have any apps, but right now hs project dev doesn't tell you that until after prompting you to select a sandbox to test with. The way that the dev command is set up now, the LocalDevManager is responsible for determining runnable components, which happens after a lot of prompting. A more robust solution would involve determining runnable components earlier in the dev process, but I think this will work fine for now and we can make things more flexible when we rethink the dev servers/dev command.

Screenshots

Before (you get prompted)

Screenshot 2024-08-28 at 12 55 11 PM

After (exits immediately)

Screenshot 2024-08-28 at 2 07 45 PM

Who to Notify

@brandenrodgers @kemmerle @joe-yeager

camden11 commented 2 weeks ago

Ok, I updated this to move the check for runnable components out of the LocalDevManager and use existing (and more flexible) error copy