Skip to content

Clean up update-gomod.sh script#256

Open
dabradley wants to merge 1 commit intokubernetes-sigs:developmentfrom
dabradley:clean-update-gomod-script
Open

Clean up update-gomod.sh script#256
dabradley wants to merge 1 commit intokubernetes-sigs:developmentfrom
dabradley:clean-update-gomod-script

Conversation

@dabradley
Copy link
Collaborator

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
This script allows developers to upgrade the kubernetes dependencies (since their versioning is effectively broken and requires explicit 'replace' statements in the go.mod file). This PR fixes some linter issues and ensures that all necessary go mod commands are called.

Which issue(s) this PR fixes:

Fixes #

Requirements:

Special notes for your reviewer:

Release note:

none

@k8s-ci-robot k8s-ci-robot added the kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. label Jan 15, 2026
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dabradley

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Jan 15, 2026
@dabradley dabradley requested review from Copilot and removed request for andyzhangx January 15, 2026 17:47
Copy link

Copilot AI left a 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 cleans up the update-gomod.sh script by fixing shell linter issues and adding missing go mod commands. The script helps developers upgrade Kubernetes dependencies by handling the required 'replace' statements in the go.mod file.

Changes:

  • Improved error messages with example usage
  • Replaced command substitution with mapfile for better array handling
  • Added proper variable quoting for shell best practices
  • Added missing go mod commands (get, download, tidy, vendor) for complete dependency management

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@coveralls
Copy link

coveralls commented Jan 15, 2026

Pull Request Test Coverage Report for Build 21041158348

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 87.64%

Totals Coverage Status
Change from base Build 20998306893: 0.0%
Covered Lines: 1950
Relevant Lines: 2225

💛 - Coveralls

@dabradley dabradley force-pushed the clean-update-gomod-script branch from 1d8707a to f6ea04b Compare January 15, 2026 17:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants