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

Adding collection name requirement checks #232

Merged
merged 3 commits into from
Jun 18, 2024

Conversation

alisonlhart
Copy link
Contributor

FIxes: #230

Adds checks for collection name requirements and new tests for the new checks.

Examples:

Command: ansible-creator init COLLECTION.NAME
Error output: Error: Collection name can only contain lower case letters, underscores, and numbers and cannot begin with an underscore.

Command: ansible-creator init na.co
Error output: Error: Collection namespace and name must be longer than 2 characters.

@alisonlhart alisonlhart added the enhancement New feature or request label Jun 18, 2024
@alisonlhart alisonlhart requested a review from a team as a code owner June 18, 2024 17:18
@alisonlhart alisonlhart requested review from ssbarnea, shatakshiiii, NilashishC and cidrblock and removed request for a team June 18, 2024 17:18
@alisonlhart alisonlhart force-pushed the collection-naming-checks branch from e5f079a to 037719b Compare June 18, 2024 17:19
* Adds constant (equal to int 2) for collection name length

* Adds a check for collection name length

* Adds a check for collection name characters

* Adds tests for the new checks
@alisonlhart alisonlhart force-pushed the collection-naming-checks branch from 037719b to 0580cbb Compare June 18, 2024 17:28
Copy link
Collaborator

@cidrblock cidrblock left a comment

Choose a reason for hiding this comment

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

awesome

@cidrblock cidrblock merged commit 2f6c733 into ansible:main Jun 18, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

RFE: Check for namespace & collection name requirements when validating arguments
2 participants