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

introduce Lintable interace #553

Merged
merged 2 commits into from
Sep 22, 2023
Merged

introduce Lintable interace #553

merged 2 commits into from
Sep 22, 2023

Conversation

lsviben
Copy link
Contributor

@lsviben lsviben commented Sep 20, 2023

Description of your changes

Introduces a Lintable interface as a common API for lintable packages.
Resolves one of the TODO's in up xpkg that we are planning to move to Crossplane, so
that we avoid code duplication for the migration.

I have:

  • Read and followed Crossplane's contribution process.
  • Run make reviewable test to ensure this PR is ready for review.

How has this code been tested

Just ran the unit tests.

Signed-off-by: lsviben <[email protected]>
@lsviben lsviben requested a review from phisco September 20, 2023 13:01
@lsviben lsviben requested review from a team as code owners September 20, 2023 13:01
@lsviben lsviben requested a review from pedjak September 20, 2023 13:01
@lsviben lsviben changed the title introduce Lintable introduce Lintable interace Sep 20, 2023
@@ -33,6 +33,12 @@ import (
"github.com/crossplane/crossplane-runtime/pkg/errors"
)

// Lintable defines the common API for lintable packages.
type Lintable interface {
GetMeta() []runtime.Object
Copy link
Contributor

Choose a reason for hiding this comment

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

what is the semantic difference between these two methods, since they return the same types? Can you please add some doc?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added some comments, hope it makes it more clear!

Signed-off-by: lsviben <[email protected]>
@phisco phisco requested a review from pedjak September 22, 2023 10:33
@phisco phisco merged commit b82c293 into crossplane:master Sep 22, 2023
8 checks passed
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.

3 participants