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

Fix make generate-deploy #2789

Merged
merged 2 commits into from
Jan 27, 2020
Merged

Conversation

2opremio
Copy link
Contributor

@2opremio 2opremio commented Jan 27, 2020

It was failing with

$ make generate-deploy
go generate ./pkg/install
go: directory pkg/install is outside main module
make: *** [pkg/install/generated_templates.gogen.go] Error 1

Also, make sure that the dependencies of pkg/install/generate.go are included in go.mod (I didn't know that the tools build tag was treated specially).

Followup from #2779

Alfonso Acosta added 2 commits January 27, 2020 14:08
It was failing with

```
$ make generate-deploy
go generate ./pkg/install
go: directory pkg/install is outside main module
make: *** [pkg/install/generated_templates.gogen.go] Error 1
```
@2opremio 2opremio requested review from squaremo and hiddeco January 27, 2020 13:08
@2opremio
Copy link
Contributor Author

2opremio commented Jan 27, 2020

Also, make sure that the dependencies of pkg/install/generate.go are included in go.mod (I didn't know that the tools build tag was treated specially).

Followup from #2779

Maybe we should fix this instead by moving pkg/install/generate.go to pkg/cmd/something. I don't think that external users of pkg/install should need to pull vfsgen since it's only a compile-time dependency.

Now, maybe this is just a micro-optimization which isn't worth it?

Even better than that it would be for Go to figure out which of the dependencies from a given package are used and not enforce building and getting everything in their go.mod (that would have saved used from needing #2779 in the first place. Maybe this isn't possible for some fundamental reason I am missing?

@2opremio 2opremio merged commit fca827c into fluxcd:master Jan 27, 2020
@2opremio 2opremio deleted the fix-pkg-install-generation branch January 27, 2020 14:15
@2opremio 2opremio added this to the 1.18.0 milestone Jan 27, 2020
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.

2 participants