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

[Feat][kubectl-plugin] Add kubectl ray version command #2424

Conversation

MortalHappiness
Copy link
Member

Why are these changes needed?

See the description in the corresponding issue for details.

Related issue number

Closes: #2423

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • This PR is not tested :(

@MortalHappiness MortalHappiness force-pushed the feature/#2423-kubectl-ray-version branch from 27040b0 to 86a9f3d Compare October 4, 2024 00:55
Copy link
Member

@kevin85421 kevin85421 left a comment

Choose a reason for hiding this comment

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

can you add a screenshot for the result of this command?

@@ -16,6 +16,7 @@ builds:
- arm64
main: ./cmd
binary: kubectl-ray
ldflags: -X github.com/ray-project/kuberay/kubectl-plugin/pkg/cmd/version.Version={{- .Tag -}}
Copy link
Member

Choose a reason for hiding this comment

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

what is the value of .Tag?

Copy link
Member Author

Choose a reason for hiding this comment

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

A git tag, semver tag. e.g. v1.0.0

"github.com/spf13/cobra"
)

var Version = "development"
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
var Version = "development"
const Version string = "development"

Copy link
Member Author

Choose a reason for hiding this comment

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

This cannot be replaced with const. This variable will be override by ldflags at build time.

@kevin85421 kevin85421 self-assigned this Oct 4, 2024
@MortalHappiness
Copy link
Member Author

image

@andrewsykim andrewsykim merged commit bee1b71 into ray-project:master Oct 4, 2024
27 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] Add kubectl ray version command
3 participants