Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
521 views
in Technique[技术] by (71.8m points)

macos - Installing Ruby on Mac OS High Sierra error

I've been trying to create a static website using Jekyll static website generator but for using it I have to install ruby using my terminal. But when I run brew install ruby I get this message error and I couldn't find a solution yet.

Warning: You are using macOS 10.13.
We (and Apple) do not provide support for this old version.
You will encounter build failures with some formulae.
Please create pull requests instead of asking for help on Homebrew's GitHub,
Twitter or any other official channels. You are responsible for resolving
any issues you experience while you are running this
old version.

Error: ruby: no bottle available!
You can try to install from source with:
 brew install --build-from-source ruby
Please note building from source is unsupported. You will encounter build
failures with some formulae. If you experience any issues please create pull
requests instead of asking for help on Homebrew's GitHub, Twitter or any other
official channels.

Should I install it from source as the error message says ?

question from:https://stackoverflow.com/questions/65886980/installing-ruby-on-mac-os-high-sierra-error

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You can try install a Ruby Manager with Homebrew. I prefer to use rbenv. There are other options, notably rvm. Choose one and stick to it.

If you choose to use rbenv

brew install ruby-build rbenv

Follow the brew caveats in your terminal to add any needed environmental variables.

To list available versions

rbenv install --list

Install the one you like

rbenv install <version number>

As mentioned in a comment you may run into more issues down the line so if possible upgrade macOS version.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...