Skip to content

Feature - CLI Prompt with Validation #800

Description

@natanfelles

Hello!

Today I was testing the CLI and it is awesome. 😄

Then I created a Command to insert/update values in a DB table or simply to get validated data.

I see that the prompt() validates required and in_list values. Then I thought about to use the full Validation Library Rules and implemented some adjusts.

With this is possible continue to prompt until the input be valid:

$email = CLI::prompt2('Email', null, 'required|valid_email');

If you think that this can be useful do some analysis in the latest commits of this branch.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions