-
-
Notifications
You must be signed in to change notification settings - Fork 5
Chore/update dependencies #15
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request updates dependency versions, modernizes various command definitions, and enhances workflow configurations. Key changes include updating Go versions and dependencies, replacing deprecated functions (e.g. ioutil.ReadAll with io.ReadAll), and refining GitHub Actions workflows including the removal of the CodeQL analysis workflow.
Reviewed Changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
go.mod | Updated Go version, toolchain, and dependency versions. |
ferret/main.go | Modernized command signature for cleaner handling. |
config/context.go | Introduced custom context key type for improved safety. |
cmd/version.go, config.go, etc. | Updated command functions to use underscore for unused args. |
.github/workflows/*.yaml | Upgraded GitHub Actions versions and added permissions. |
.github/dependabot.yml | Added Dependabot configuration file. |
.github/workflows/codeql-analysis.yml | Removed the CodeQL workflow file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR modernizes the codebase by updating dependencies, workflows, and command definitions, aiming for improved maintainability, security, and performance.
- Updated go.mod with current dependency versions and a new Go toolchain requirement
- Upgraded GitHub Actions workflows and removed the deprecated CodeQL workflow
- Modernized command implementations by using underscore for unused parameters and replacing deprecated functions
Reviewed Changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated no comments.
Show a summary per file
File | Description |
---|---|
go.mod | Updated Go version, toolchain, and dependency versions |
ferret/main.go | Adjusted PersistentPreRun function signature to ignore unused parameters |
config/context.go | Replaced an anonymous struct with a custom type for context keys |
cmd/version.go | Updated PreRun to ignore unused parameters |
cmd/update.go | Revised function signature to ignore unused command parameter |
cmd/exec.go | Replaced deprecated ioutil.ReadAll with io.ReadAll and updated function signatures |
cmd/config.go | Adjusted RunE and Run functions to use underscore for unused parameters |
cmd/browser.go | Updated PersistentPreRun functions to consistently ignore unused parameters |
.goreleaser.yml | Updated configuration syntax and versioning details |
.github/workflows/release.yaml | Updated actions versions, Go version, and added explicit permissions |
.github/workflows/codeql-analysis.yml | Removed deprecated CodeQL analysis workflow |
.github/workflows/build.yml | Upgraded actions versions and Go version |
.github/dependabot.yml | Added Dependabot configuration for automated dependency updates |
This pull request introduces several updates across the repository, focusing on dependency management, workflow updates, code modernization, and general cleanup. Key highlights include upgrading dependencies and GitHub Actions versions, removing deprecated CodeQL analysis, and improving code readability by replacing outdated practices.
Dependency Management and Configuration Updates:
dependabot.yml
configuration to enable weekly automated dependency updates for Go modules. (.github/dependabot.yml
)1.23.0
with a toolchain requirement of1.24.2
and updated dependencies ingo.mod
for compatibility and security improvements. (go.mod
)GitHub Actions Workflow Updates:
actions/checkout
to v4 andactions/setup-go
to v5 inbuild.yml
,release.yaml
, and other workflows, ensuring compatibility with newer Go versions (>=1.24
). (.github/workflows/build.yml
,.github/workflows/release.yaml
) [1] [2]codeql-analysis.yml
workflow, as it is no longer required for this repository. (.github/workflows/codeql-analysis.yml
)Code Modernization:
ioutil.ReadAll
withio.ReadAll
incmd/exec.go
to use the latest Go standard library practices. (cmd/exec.go
)cobra.Command
handlers to use_
for unused arguments, improving code clarity and adhering to best practices. (cmd/browser.go
,cmd/config.go
,cmd/exec.go
,cmd/update.go
,cmd/version.go
,ferret/main.go
) [1] [2] [3] etc.)Configuration and Build Improvements:
.goreleaser.yml
to version 2, modernized archive naming templates, and improved snapshot versioning. (.goreleaser.yml
) [1] [2]General Cleanup:
ctxKeyT
for context keys to avoid potential collisions and improve type safety. (config/context.go
)