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

Cleanup controller gen and proto gen #667

Merged
merged 1 commit into from
Jan 10, 2023

Conversation

chrisdoherty4
Copy link
Member

@chrisdoherty4 chrisdoherty4 commented Jan 10, 2023

Controller gen has an opinionated directory structure that doesn't typically compliment Go guidelines on project structure. This change tidies controller sources used for code gen to better align with Go project structure best practice.

Additionally, the proto files that are generated and only used internally have been moved to internal along with much of the controller code.

This PR does not address exported APIs that are only used by the packages they reside in or other similar anti-patterns. Similarly, this PR does not seek to change any types/type structures meaning consumers can merely change the import path and expect the imports to continue to work.

Signed-off-by: Chris Doherty [email protected]

@chrisdoherty4 chrisdoherty4 force-pushed the feat/cleanup branch 2 times, most recently from 4fdd3d6 to ae87efa Compare January 10, 2023 01:49
@codecov
Copy link

codecov bot commented Jan 10, 2023

Codecov Report

Merging #667 (2bc83b8) into main (d9f025f) will increase coverage by 0.20%.
The diff coverage is 40.78%.

❗ Current head 2bc83b8 differs from pull request most recent head 80358d3. Consider uploading reports for the commit 80358d3 to get more accurate results

@@            Coverage Diff             @@
##             main     #667      +/-   ##
==========================================
+ Coverage   50.96%   51.17%   +0.20%     
==========================================
  Files          19       18       -1     
  Lines         985      981       -4     
==========================================
  Hits          502      502              
+ Misses        477      473       -4     
  Partials        6        6              
Impacted Files Coverage Δ
api/v1alpha1/hardware_methods.go 100.00% <ø> (ø)
api/v1alpha1/hardware_types.go 100.00% <ø> (ø)
api/v1alpha1/template_methods.go 100.00% <ø> (ø)
api/v1alpha1/template_types.go 100.00% <ø> (ø)
api/v1alpha1/workflow_methods.go 76.27% <ø> (ø)
api/v1alpha1/workflow_types.go 100.00% <ø> (ø)
cmd/tink-worker/worker/worker.go 0.00% <0.00%> (ø)
internal/controller/manager.go 40.00% <ø> (ø)
internal/server/kubernetes_api.go 0.00% <0.00%> (ø)
internal/workflow/template_funcs.go 100.00% <ø> (ø)
... and 4 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@chrisdoherty4 chrisdoherty4 force-pushed the feat/cleanup branch 2 times, most recently from 13adfa3 to e7a441e Compare January 10, 2023 02:05
Controller gen has an opinionated directory structure that doesn't
typically compliment Go guidelines on project structure. This change
tidies controller sources used for code gen to better align with Go
project structure best practice.

Additionally, the proto files that are generated and only used
internally have been moved to `internal`.

Signed-off-by: Chris Doherty <[email protected]>
@jacobweinstock jacobweinstock added the ready-to-merge Signal to Mergify to merge the PR. label Jan 10, 2023
@mergify mergify bot merged commit 11fcfba into tinkerbell:main Jan 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge Signal to Mergify to merge the PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants