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

Use inquirer for confirm prompt #5061

Merged
merged 1 commit into from
Jun 21, 2024
Merged

Use inquirer for confirm prompt #5061

merged 1 commit into from
Jun 21, 2024

Conversation

mat-if
Copy link
Contributor

@mat-if mat-if commented Jun 20, 2024

Summary

This also creates an abstraction for the confirm prompt as well as a confirm-or-quit function so it is easier to use confirm logic in commands

This is part of oclif 4.x upgrade prep

Trade-offs

We're trading our manually-added "Do you confirm (Y)es/(N)o" for the library appended "(Y/n)". There is no easy way to override this, short of upgrading the version of inquirer we use. However, the new version of inquirer is an ECMAScript Module, which on its own is solvable, but on top of that, the @types/inquirer library is quite outdated, which would require us to write our own types to use it, which is more work than it is worth right now.

image

Testing Plan

Manual testing

Documentation

N/A

Breaking Change

N/A

@mat-if mat-if force-pushed the mat/confirm branch 2 times, most recently from 6152956 to e2d7472 Compare June 21, 2024 21:49
@mat-if mat-if marked this pull request as ready for review June 21, 2024 22:11
@mat-if mat-if requested a review from a team as a code owner June 21, 2024 22:11
This also creates an abstraction for the confirm prompt so it is easier to use
confirm logic in commands
@mat-if mat-if merged commit c14b401 into staging Jun 21, 2024
9 checks passed
@mat-if mat-if deleted the mat/confirm branch June 21, 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