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

Register at a homebrew official repository #11

Closed
c-bata opened this issue Sep 4, 2017 · 9 comments
Closed

Register at a homebrew official repository #11

c-bata opened this issue Sep 4, 2017 · 9 comments

Comments

@c-bata
Copy link
Owner

c-bata commented Sep 4, 2017

kube-prompt is gradually becoming a little bit famous. So perhaps it is the worth to register at a homebrew official repository.
It is a little bit comfortable because we don't need brew tap.

@c-bata
Copy link
Owner Author

c-bata commented Sep 4, 2017

Is there a someone who want to register kube-prompt at homebrew official repository?

@yermulnik
Copy link

yermulnik commented Feb 10, 2021

Is it possible to add Linux flavour to brew formulae?
Currently it installs MacOS binary on Linux:

> uname -srm
Linux 4.4.0-200-generic x86_64

> brew install c-bata/kube-prompt/kube-prompt
==> Tapping c-bata/kube-prompt
Cloning into '/home/linuxbrew/.linuxbrew/Homebrew/Library/Taps/c-bata/homebrew-kube-prompt'...
remote: Enumerating objects: 3, done.
remote: Counting objects: 100% (3/3), done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 33 (delta 0), reused 2 (delta 0), pack-reused 30
Receiving objects: 100% (33/33), done.
Resolving deltas: 100% (9/9), done.
Tapped 1 formula (26 files, 99.9KB).
==> Installing kube-prompt from c-bata/kube-prompt
==> Downloading https://github.com/c-bata/kube-prompt/releases/download/v1.0.10/kube-prompt_v1.0.10_darwin_amd64.zip
==> Downloading from https://github-releases.githubusercontent.com/100288067/7fb1f900-1592-11ea-99d6-ac1cccbb4ee4?X-Amz-
######################################################################## 100.0%
🍺  /home/linuxbrew/.linuxbrew/Cellar/kube-prompt/1.0.10: 3 files, 31.6MB, built in 1 second

> file /home/linuxbrew/.linuxbrew/Cellar/kube-prompt/1.0.10/bin/kube-prompt
/home/linuxbrew/.linuxbrew/Cellar/kube-prompt/1.0.10/bin/kube-prompt: Mach-O 64-bit x86_64 executable

Thanks in advance

@c-bata
Copy link
Owner Author

c-bata commented Feb 12, 2021

Hi @yermulnik! Thank you for your comment.

I've just checked the Formulae Cookbook but found no descriptions to support Linux.
https://docs.brew.sh/Formula-Cookbook

Do you know how to write Homebrew Formulae for Linux? The formulae is on following repository so that I'm also welcome your pull request if you can.
https://github.com/c-bata/homebrew-kube-prompt

@yermulnik
Copy link

Hi @c-bata

Unfortunately I'm not very familiar with brew yet to provider proper PR for the kube-prompt formulae but this looks to be a quick example which fits this case: https://github.com/minamijoyo/homebrew-tfupdate/blob/master/tfupdate.rb

I've also took a look through some of formulaes with Linux support but most of these seem to be too complicated for me to understand how these work w/o good knowledge with brew formulaes: https://formulae.brew.sh/formula-linux/

Let me know whether you're fine with the way tfupdate formulae is constructed and I'll try and replicate this via PR to https://github.com/c-bata/homebrew-kube-prompt

@c-bata
Copy link
Owner Author

c-bata commented Mar 1, 2021

@yermulnik I'm really sorry for the delayed response.

Let me know whether you're fine with the way tfupdate formulae is constructed and I'll try and replicate this via PR to https://github.com/c-bata/homebrew-kube-prompt

Welcome. I will review your pull request.

@yermulnik
Copy link

@c-bata No worries. Here it is: c-bata/homebrew-kube-prompt#2
Verified to be functional on Linux:

> brew reinstall kube-prompt
==> Downloading https://github.com/c-bata/kube-prompt/releases/download/v1.0.11/kube-prompt_v1.0.11_linux_amd64.zip
==> Downloading from https://github-releases.githubusercontent.com/100288067/90281100-6b51-11eb-8d29-0058cc5def4a?X-Amz-
######################################################################## 100.0%
==> Reinstalling c-bata/kube-prompt/kube-prompt
🍺  /home/linuxbrew/.linuxbrew/Cellar/kube-prompt/1.0.11: 3 files, 36MB, built in 2 seconds

> file /home/linuxbrew/.linuxbrew/bin/kube-prompt
/home/linuxbrew/.linuxbrew/bin/kube-prompt: symbolic link to ../Cellar/kube-prompt/1.0.11/bin/kube-prompt

> file /home/linuxbrew/.linuxbrew/bin/../Cellar/kube-prompt/1.0.11/bin/kube-prompt
/home/linuxbrew/.linuxbrew/bin/../Cellar/kube-prompt/1.0.11/bin/kube-prompt: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, not stripped

> /home/linuxbrew/.linuxbrew/bin/kube-prompt
error invalid configuration: no configuration has been provided

You also may want to look into GoReleaser to re-generate homebrew formulae when releasing new version: https://goreleaser.com/customization/homebrew/

@c-bata
Copy link
Owner Author

c-bata commented Mar 5, 2021

I merged your PR. Thank you for your contribution.

error invalid configuration: no configuration has been provided

Hmm... The error seems to be related to #54.

@c-bata
Copy link
Owner Author

c-bata commented Mar 5, 2021

Let me close this issue since I lost the motivation to register at HomeBrew official repository.

@c-bata c-bata closed this as completed Mar 5, 2021
@yermulnik
Copy link

@c-bata Thanks for merging PR.

Hmm... The error seems to be related to #54.

Nah, disregard this. This was just to show that I got correct binary installed with the fixed brew formulae. And kube-prompt errored out just because I didn't have any kube config in place.
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants