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

(ci) update github actions ci to use a single GO_VERSION variable #2806

Merged
merged 6 commits into from
Oct 30, 2023

Conversation

ramin
Copy link
Contributor

@ramin ramin commented Oct 4, 2023

This sets a single variable (GO_VERSION) in the main ci.yml workflow, which will be the single place we set the current go version. We then run a setup job that sets an required output for subsequent jobs to use, adding:

with:
  go-version: ${{ needs.setup.outputs.go-version }}

Where we had previously either:

  1. duplicated the GO_VERSION env var in that workflow
  2. passed in 1.21 or whatever go version explicitly

When the rpc openrpc.json workflow check changes are merged, this will also prevent another duplication of the go version appearing.

refs #2698

@ramin ramin added the kind:ci CI related PRs label Oct 4, 2023
@ramin ramin self-assigned this Oct 4, 2023
@codecov-commenter
Copy link

codecov-commenter commented Oct 4, 2023

Codecov Report

Merging #2806 (15b3f6d) into main (565691f) will increase coverage by 0.24%.
Report is 1 commits behind head on main.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #2806      +/-   ##
==========================================
+ Coverage   51.57%   51.81%   +0.24%     
==========================================
  Files         167      167              
  Lines       10787    10787              
==========================================
+ Hits         5563     5589      +26     
+ Misses       4735     4706      -29     
- Partials      489      492       +3     

see 6 files with indirect coverage changes

@ramin ramin changed the title [DRAFT] update ci to use a single GO_VERSION (ci) update github actions ci to use a single GO_VERSION variable Oct 4, 2023
@ramin ramin marked this pull request as ready for review October 4, 2023 12:24
@ramin ramin requested a review from MSevey October 4, 2023 12:24
Copy link
Member

@MSevey MSevey left a comment

Choose a reason for hiding this comment

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

Nice! Beside not skipping for dependabot this lgtm.

This is a good workaround not having global env in the actions. The alternative would be to set a secret but then we can't actually see the version, so this is better.

cc @celestiaorg/devops for visibility and helping to reapply elsewhere.

.github/workflows/ci_release.yml Outdated Show resolved Hide resolved
@ramin ramin requested a review from MSevey October 23, 2023 15:20
MSevey
MSevey previously approved these changes Oct 24, 2023
Wondertan
Wondertan previously approved these changes Oct 24, 2023
@ramin ramin dismissed stale reviews from Wondertan and MSevey via 15b3f6d October 26, 2023 02:50
@ramin
Copy link
Contributor Author

ramin commented Oct 26, 2023

had to resolve conflict on this

@ramin ramin requested a review from MSevey October 26, 2023 13:44
@ramin ramin requested a review from Wondertan October 26, 2023 13:44
@ramin ramin merged commit 1552e9e into main Oct 30, 2023
17 of 19 checks passed
@ramin ramin deleted the ci/ramin/go-variable branch October 30, 2023 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:ci CI related PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants