Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Remove lint from non-relevant places #126

Closed
wants to merge 2 commits into from
Closed

Conversation

khos2ow
Copy link

@khos2ow khos2ow commented Nov 9, 2020

Remove lint jobs and targets from processes and targets which they don't necessarily need to run lint. Notable changes:

  • make build: make build.check was removed from it
  • make helm.check: new target added for linting helm chart
  • make go.vendor.tidy: new target for go mod tidy which will be used in upstream projects' targets (e.g. make reviewable).

This PR blocks crossplane/crossplane#1950 and should be reviewed as a pair.

Signed-off-by: Khosrow Moossavi <khos2ow@gmail.com>
@khos2ow khos2ow changed the title Add go.vendor.tidy target Remove lint from non-relevant places Nov 9, 2020
Copy link
Contributor

@hasheddan hasheddan left a comment

Choose a reason for hiding this comment

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

@khos2ow is the title for this PR related to the intended behavior? It looks like we just call go mod tidy directly in c/c, so it isn't immediately apparent to me how this facilitates removing lint

@khos2ow
Copy link
Author

khos2ow commented Nov 9, 2020

@hasheddan No, I should've converted it to draft a while ago. This is me attempting to move linting only to relevant CI jobs and targets. I was about to update this PR and consecutively open a corresponding PR in c/c.

Signed-off-by: Khosrow Moossavi <khos2ow@gmail.com>
@khos2ow khos2ow marked this pull request as ready for review November 10, 2020 00:47
@khos2ow
Copy link
Author

khos2ow commented Nov 10, 2020

@negz @hasheddan this should be good for review now.

@@ -300,7 +300,6 @@ do.build.artifacts: $(foreach p,$(PLATFORMS), do.build.artifacts.$(p))
# build for all platforms
build.all:
@$(MAKE) build.init
@$(MAKE) build.check
Copy link
Author

Choose a reason for hiding this comment

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

The most notable change here is that this line is removed. As I mentioned before this is really debatable. It's quite nice to have it executed as part of the build process, but at the same time the CI is in place and does that, separately on different job.

Copy link
Member

Choose a reason for hiding this comment

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

One thing to note here is that this build submodule is used by several Upbound internal projects, so these changes could affect more than just Crossplane. :( I think we eventually should fork the build library under the Crossplane org so that folks without visibility into Upbound's private repos can make changes safely.

This was mentioned in crossplane/crossplane#1583, which I accidentally closed while only half done.

Copy link
Author

Choose a reason for hiding this comment

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

That's a really valid point! Maybe as an interim workaround (before forking this under crossplane org) an environment variable can be added to disable this.

RUN_BUILD_CHECK ?=true
build.all:
	@$(MAKE) build.init
ifeq ($(RUN_BUILD_CHECK),"true")
	@$(MAKE) build.check
endif

@negz negz mentioned this pull request Jun 14, 2021
3 tasks
@haarchri haarchri closed this Nov 2, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants