Skip to content
Snippets Groups Projects
Commit 50f47e88 authored by Maxim Belkin's avatar Maxim Belkin
Browse files

utils/ruby.sh: reoganize code

Moved OS-specific logic to functions:
 - `find_ruby`: returns (via echo) Ruby that can be used
 - `usable_ruby`: checks whether Ruby satisfies Homebrew

Pre-create OS-specific error messages:
 - `upgrade_fail`: message that is printed when Homebrew fails to upgrade
   vendor Ruby
 - `install_fail`: message that is printed when Homebrew fails to install
   vendor Ruby

Unconditionally set `TERMINFO_DIRS` when installing/upgrading vendor Ruby
**but** export it on Linux only.

Motivation: move OS-specific logic to functions so that it's easier to
understand the main steps.
parent 9fa67ba3
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment