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

Upgrade to go 1.18 #5542

Merged
merged 1 commit into from May 9, 2022
Merged

Upgrade to go 1.18 #5542

merged 1 commit into from May 9, 2022

Conversation

samcoe
Copy link
Member

@samcoe samcoe commented Apr 28, 2022

This PR updates the project to Go 1.18.

As part of this PR I had to update our version of golangci-lint to support the new Go version. With this new version there are four linters that are currently disabled as being unsupported:

  • gosimple
  • staticcheck
  • structcheck
  • unused

They are currently being worked on to support Go 1.18.

Additionally due to the fact that the staticcheck linter is not supported and we use //nolint:staticcheck in a number of places to hide deprecation warnings from the linter I also had to disable the nolintlint linter so these annotations do not cause linter errors.

In the near future we will want to update our version of golangci-lint to get these 5 linters re-enabled.

Copy link

@kayal2019 kayal2019 left a comment

go.mod

@samcoe samcoe marked this pull request as ready for review May 2, 2022
@samcoe samcoe requested a review from as a code owner May 2, 2022
@samcoe samcoe requested review from mislav (assigned from cli/code-reviewers) and removed request for May 2, 2022
@cliAutomation cliAutomation added this to Needs review 🤔 in The GitHub CLI May 2, 2022
mislav
mislav approved these changes May 4, 2022
Copy link
Member

@mislav mislav left a comment

This looks good; thanks for doing the migration!

Do you expect to get any benefit from the 1.18 migration? Are there some 1.17 or 1.18 features that we hope to use? Or is this purely housekeeping

The GitHub CLI automation moved this from Needs review 🤔 to Needs to be merged 🎉 May 4, 2022
@samcoe
Copy link
Member Author

@samcoe samcoe commented May 4, 2022

@mislav This is mostly just housekeeping. I did end up back porting a newly added 1.18 feature strings.Cut in this pr, so that could be replaced once this is merged.

@samcoe samcoe merged commit 597eb16 into trunk May 9, 2022
11 checks passed
The GitHub CLI automation moved this from Needs to be merged 🎉 to Pending Release 🥚 May 9, 2022
@samcoe samcoe deleted the go-1.18 branch May 9, 2022
@github-actions github-actions bot moved this from Pending Release 🥚 to Done 💤 in The GitHub CLI May 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
The GitHub CLI
  
Done 💤
Development

Successfully merging this pull request may close these issues.

None yet

3 participants