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

feat: new inquirer #489

Merged
merged 9 commits into from
Jan 8, 2024
Merged

feat: new inquirer #489

merged 9 commits into from
Jan 8, 2024

Conversation

mshanemc
Copy link
Contributor

@mshanemc mshanemc commented Dec 30, 2023

What does this PR do?

switch to the new inquirer (large refactor)

bugs fixed:

  1. schema generate field wouldn't prompt for externalId except for customObjects (it should have), but would for Platform Event fields (it shouldn't)

features

  1. schema generate platformevent now provides customized instructions for creating a field, similar to how schema generate sobject did

What issues does this PR fix or reference?

prerequisite for @W-14674359@ (which will remove old inquirer that this was using)
@W-13801582@

@mshanemc mshanemc requested a review from a team as a code owner December 30, 2023 06:22
@mshanemc mshanemc changed the title Sm/new-inquirer feat: new inquirer Jan 4, 2024
@mdonnalley
Copy link
Contributor

mdonnalley commented Jan 8, 2024

QA:

linked to sf and run from dreamhouse-lwc project

schema generate field --label foo
Which object selector shows all custom objects
API name defaults to foo__c
API name does not enforce __c suffix
Field type selector shows all the field types

  • AutoNumber type causes Starting number prompt
  • Checkbox type causes default prompt
  • Currency type causes Number of decimal places, Total number of digits prompts
  • HTML type causes length, visible lines prompts
  • Location type causes Number of decimal places prompt
  • LongTextArea type causes length, visible lines prompts
  • Number type causes Number of decimal places , Total number of digits prompts
  • Text type causes length prompt

Description is required
Help text is optional
Security classification selector shows all the types
✅ field is successfully generated

schema generate sobject --label foo
Which local directory
Plural label defaults to foos
API name defaults to foo__c
API name does not enforce __c suffix
Description is required
Name field defaults to foo Name
type selector shows all types
enable enterprise features confirmation
enable history confirmation
enable activities confirmation
enable search confirmation
enable feeds confirmation
enable reports confirmation
org-wide sharing model selector shows ReadWrite, Read, Private
✅ sobject successfully created

sf schema generate tab --object Broker__c --directory force-app/main/default/tabs
✅ tab successfully generated

sf schema generate platformevent --label foo
Which local directory
API name defaults to foo__e
API name does not enforce __e suffix
Plural label defaults to foos
Description is required
completes, or immediately selector shows PublishImmediately and PublishAfterCommit
✅ platform event successfully created

@mdonnalley
Copy link
Contributor

QA Round 2

schema generate field --label foo
API name enforces __c suffix

schema generate sobject --label foo
API name enforces __c suffix

schema generate platformeven --label foo
API name enforces __e suffix

@mdonnalley mdonnalley merged commit 447757a into main Jan 8, 2024
10 checks passed
@mdonnalley mdonnalley deleted the sm/new-inquirer branch January 8, 2024 22:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants