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

[cli] prompt for an app selector rather than pasting an id #532

Merged
merged 3 commits into from
Nov 22, 2024
Merged

Conversation

stopachka
Copy link
Contributor

Previously, we prompted for an app id. That's kind of a sadder experience though. Instead, we now fetch apps and let the user select:

image

@stopachka stopachka changed the base branch from main to cli5 November 22, 2024 22:46
Copy link

View Vercel preview at instant-www-js-cli6-jsv.vercel.app.

Copy link
Contributor

@dwwoelfel dwwoelfel left a comment

Choose a reason for hiding this comment

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

LGTM!

const choice = await select({
message: "Which app would you like to import?",
choices: res.data.apps.map((app) => {
return { name: app.title, value: app.id };
Copy link
Contributor

@dwwoelfel dwwoelfel Nov 22, 2024

Choose a reason for hiding this comment

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

Maybe we ought to do `${app.title} (${app.id})`?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I like it!

Base automatically changed from cli5 to main November 22, 2024 22:57
@stopachka stopachka merged commit 8567e59 into main Nov 22, 2024
24 checks passed
@stopachka stopachka deleted the cli6 branch November 22, 2024 22:59
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.

2 participants