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: hide resources #254

Merged
merged 4 commits into from
May 9, 2024
Merged

feat: hide resources #254

merged 4 commits into from
May 9, 2024

Conversation

dbolson
Copy link
Contributor

@dbolson dbolson commented May 8, 2024

Refactors the resource code a bit and then filters out "other" and "oauth2 clients" endpoints.

Requirements

  • I have added test coverage for new or changed functionality
  • I have followed the repository's pull request submission guidelines
  • I have validated my changes against all supported platform versions

Related issues

Provide links to any issues in this repository or elsewhere relating to this pull request.

Describe the solution you've provided

Provide a clear and concise description of what you expect to happen.

Describe alternatives you've considered

Provide a clear and concise description of any alternative solutions or features you've considered.

Additional context

Add any other context about the pull request here.


build:
go build -o ldcli

generate:
Copy link
Contributor Author

Choose a reason for hiding this comment

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

You can run make generate if that's easier.

@@ -149,6 +133,42 @@ func GetTemplateData(fileName string) (TemplateData, error) {
return TemplateData{Resources: resources}, nil
}

func NewResourceData(tag openapi3.Tag) ResourceData {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Made some constructor functions to encapsulate the rules for creating a resource data struct type. This is simpler to test than setting up JSON and calling GetTemplateData.

@dbolson dbolson requested a review from k3llymariee May 8, 2024 22:06
Copy link
Contributor

@k3llymariee k3llymariee left a comment

Choose a reason for hiding this comment

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

ty!!

@dbolson dbolson merged commit af22b5d into main May 9, 2024
2 checks passed
@dbolson dbolson deleted the sc-/hide-resources branch May 9, 2024 17: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