-
-
Notifications
You must be signed in to change notification settings - Fork 12.4k
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
kfctl 1.1.0 (new formula) #65230
kfctl 1.1.0 (new formula) #65230
Changes from all commits
5854acf
10494c8
5d12daa
c70ccaf
0fdfab5
276577e
51ce998
f950f54
5f91c98
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
class Kfctl < Formula | ||
desc "Kubeflow command-line interface" | ||
homepage "https://github.com/kubeflow/kfctl" | ||
url "https://github.com/kubeflow/kfctl.git", | ||
tag: "v1.1.0", | ||
revision: "9a3621e2b2ce6d2baa5c78acccec5028c4e4cbe1" | ||
license "Apache-2.0" | ||
|
||
depends_on "go@1.13" => :build | ||
|
||
def install | ||
system "make", "build" | ||
bin.install "bin/darwin/kfctl" | ||
|
||
# Install bash completion | ||
output = Utils.safe_popen_read("#{bin}/kfctl", "completion", "bash") | ||
(bash_completion/"kfctl").write output | ||
|
||
# Install zsh completion | ||
output = Utils.safe_popen_read("#{bin}/kfctl", "completion", "zsh") | ||
(zsh_completion/"kfctl").write output | ||
end | ||
|
||
test do | ||
run_output = shell_output("#{bin}/kfctl version 2>&1") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We need a test that exercises the some of the functionality of the app. Version checks or usage checks (foo --version or foo --help) are not sufficient, as explained in the formula cookbook. In most cases, a good test would involve running a simple test case: run #{bin}/foo input.txt.
Some advice for specific cases:
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is similar to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That does have an additional test to test the functionality, this is not good enough There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, So do you have any suggestions? This is a CLI tool for API. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There's suggestions in my initial comment There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I disagree with the recommendations.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
They test a functional part of the application.
It's not the same tool |
||
assert_match "kfctl v1.1.0-0-g9a3621e", run_output | ||
end | ||
end |
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.
Does it not work with the most recent go?
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.
It doesn't work. https://github.com/kubeflow/kfctl/blob/master/Makefile#L16
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.
That doesn't mean it won't work with a newer version, but it does make me hesitant to accept it into homebrew, since apparently it's not trying to stay compatible with new releases, which in turn will cause problems for homebrew down the line. In februari this formula will break at this rate.
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.
I have tried compiling it in the latest version and it has an issue and that is the reason I had to fall back to
1.13
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.
So do you expect the upstream to fix this before coming with a brew formula?
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.
I expect upstream to not be a year behind in security updates. If there is no work being done to keep up to date I'd consider it abandoned and violating the rule:
https://docs.brew.sh/Acceptable-Formulae#niche-or-self-submitted-stuff
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.
I agree, closing it waiting for the upstream.