尤其是kubernetes-cli
。我已经安装了1.12.0。我需要1.11.x,但是我没有安装。
我已经审查并尝试了该线程中的所有答案,但没有任何效果:Homebrew install specific version of formula?
我尝试过brew search
,但没有窃听版本:
~ brew search kubernetes-cli
==> Formulae
kubernetes-cli ✔
我尝试过brew versions
,但该命令已删除:
~ brew versions
Error: Unknown command: versions
我尝试过brew install kubernetes-cli@1.11.0
以及.1和.2:
~ brew install kubernetes-cli@1.11.0
Error: No available formula with the name "kubernetes-cli@1.11.0"
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
==> Searching taps on GitHub...
Error: No formulae found in taps.
brew switch
要求我安装了旧版本,而我没有安装。
~ brew switch kubernetes-cli 1.11.0
Error: kubernetes-cli does not have a version "1.11.0" in the Cellar.
kubernetes-cli installed versions: 1.12.0
答案 0 :(得分:14)
Formula
文件夹kubernetes-cli.rb
文件的原始版本https://raw.githubusercontent.com/Homebrew/homebrew-core/3e8f5503dde7069c5ff49b82d5e1576e6ebe3a5d/Formula/kubernetes-cli.rb
brew install <raw_link>
答案 1 :(得分:5)
我没有足够的代表对对我有帮助的答案发表评论。因此,在此处撰写有关@urpalreloaded
的第2点的详细说明brew search kubernetes-cli@1.11.0
brew unlink kubernetes-cli
brew install <raw-link>
FWIW,我认为brew不保留版本,因为它会使回购协议太大?这种解决方法很不方便,也许他们最终可以找到解决此问题的方法?
答案 2 :(得分:0)
上面的答案非常有用,但是当我尝试在Sierra 10.12.6机器上安装Carthage 0.30.1时,出现SHA256不匹配错误:
$ brew install https://raw.githubusercontent.com/ilovezfs/homebrew-core/8c93668a451087611b2247cafe02ad6f867daed6/Formula/carthage.rb --force-bottle
######################################################################## 100.0%
Warning: carthage 0.32.0 is available and more recent than version 0.30.1.
==> Downloading https://homebrew.bintray.com/bottles/carthage-0.30.1.sierra.bottle.tar.gz
######################################################################## 100.0%
Error: SHA256 mismatch
然后由于最新的Sierra Xcode不支持新的Xcode构建系统而无法从源代码构建。
对我有用的是直接从瓶子上安装(URL显示在第一个brew install <raw url>
输出中):
brew install https://homebrew.bintray.com/bottles/carthage-0.30.1.sierra.bottle.tar.gz
答案 3 :(得分:0)
我遇到了与dsjapan相同的问题,对我来说起作用的是换成高塞拉山脉:
brew unlink carthage
brew install https://homebrew.bintray.com/bottles/carthage-0.30.1.high_sierra.bottle.tar.gz