diff --git a/cli/cli.go b/cli/cli.go index daaa998..1665551 100644 --- a/cli/cli.go +++ b/cli/cli.go @@ -33,7 +33,6 @@ import ( "pkg.re/essentialkaos/ek.v12/progress" "pkg.re/essentialkaos/ek.v12/req" "pkg.re/essentialkaos/ek.v12/signal" - "pkg.re/essentialkaos/ek.v12/sliceutil" "pkg.re/essentialkaos/ek.v12/sortutil" "pkg.re/essentialkaos/ek.v12/strutil" "pkg.re/essentialkaos/ek.v12/system" @@ -58,7 +57,7 @@ import ( // App info const ( APP = "RBInstall" - VER = "2.0.0" + VER = "2.1.0" DESC = "Utility for installing prebuilt Ruby versions to RBEnv" ) @@ -435,24 +434,24 @@ func showDetailedInfo(rubyVersion string) { url := fmt.Sprintf("%s/%s/%s", knf.GetS(STORAGE_URL), info.Path, info.File) added := timeutil.Format(time.Unix(info.Added, 0), "%Y/%m/%d %H:%M") - fmtc.Printf(" {*}%-12s{!} {s}|{!} %s\n", "Name", info.Name) - fmtc.Printf(" {*}%-12s{!} {s}|{!} %s\n", "URL", url) - fmtc.Printf(" {*}%-12s{!} {s}|{!} %s\n", "Size", fmtutil.PrettySize(info.Size)) - fmtc.Printf(" {*}%-12s{!} {s}|{!} %s\n", "Checksum", strutil.Head(info.Hash, 7)) - fmtc.Printf(" {*}%-12s{!} {s}|{!} %s\n", "Added", added) + fmtc.Printf(" {*}%-16s{!} {s}|{!} %s\n", "Name", info.Name) + fmtc.Printf(" {*}%-16s{!} {s}|{!} %s\n", "URL", url) + fmtc.Printf(" {*}%-16s{!} {s}|{!} %s\n", "Size", fmtutil.PrettySize(info.Size)) + fmtc.Printf(" {*}%-16s{!} {s}|{!} %s\n", "SHA-256 Checksum", info.Hash) + fmtc.Printf(" {*}%-16s{!} {s}|{!} %s\n", "Added", added) if isVersionInstalled(info.Name) { installDate, _ := fsutil.GetMTime(getVersionPath(info.Name)) installDateStr := timeutil.Format(installDate, "%Y/%m/%d %H:%M") - fmtc.Printf(" {*}%-12s{!} {s}|{!} Yes {s-}(%s){!}\n", "Installed", installDateStr) + fmtc.Printf(" {*}%-16s{!} {s}|{!} Yes {s-}(%s){!}\n", "Installed", installDateStr) } else { - fmtc.Printf(" {*}%-12s{!} {s}|{!} No\n", "Installed") + fmtc.Printf(" {*}%-16s{!} {s}|{!} No\n", "Installed") } if info.EOL { - fmtc.Printf(" {*}%-12s{!} {s}|{!} {r}Yes{!}\n", "EOL") + fmtc.Printf(" {*}%-16s{!} {s}|{!} {r}Yes{!}\n", "EOL") } else { - fmtc.Printf(" {*}%-12s{!} {s}|{!} No\n", "EOL") + fmtc.Printf(" {*}%-16s{!} {s}|{!} No\n", "EOL") } if len(info.Variations) != 0 { @@ -1526,12 +1525,8 @@ func checkRBEnv() { // checkDependencies check dependencies for given category func checkDependencies(info *index.VersionInfo, category string) { - rubiesOnJava := []string{index.CATEGORY_JRUBY, index.CATEGORY_TRUFFLE} - - if sliceutil.Contains(rubiesOnJava, category) { - if env.Which("java") == "" { - printErrorAndExit("Java is required for this variation of Ruby") - } + if category == index.CATEGORY_JRUBY && env.Which("java") == "" { + printErrorAndExit("Java is required for this variation of Ruby") } if strings.HasSuffix(info.Name, "jemalloc") { diff --git a/common/eol.json b/common/eol.json index a42ec27..7f42ec0 100644 --- a/common/eol.json +++ b/common/eol.json @@ -4,7 +4,10 @@ "2.0": true, "2.1": true, "2.2": true, + "2.3": true, + "2.4": true, "jruby-1.6": true, "jruby-1.7": true, - "jruby-9.0": true + "jruby-9.0": true, + "jruby-9.1": true } diff --git a/common/rbinstall.spec b/common/rbinstall.spec index 511e01c..33c4ddd 100644 --- a/common/rbinstall.spec +++ b/common/rbinstall.spec @@ -44,7 +44,7 @@ Summary: Utility for installing prebuilt Ruby to rbenv Name: rbinstall -Version: 2.0.0 +Version: 2.1.0 Release: 0%{?dist} Group: Applications/System License: EKOL @@ -56,7 +56,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: rbenv ca-certificates p7zip >= 16 -BuildRequires: golang >= 1.13 +BuildRequires: golang >= 1.14 Provides: %{name} = %{version}-%{release} @@ -143,6 +143,9 @@ rm -rf %{buildroot} ################################################################################ %changelog +* Sat Jun 20 2020 Anton Novojilov - 2.1.0-0 +- [cli] Improved UI + * Wed May 20 2020 Anton Novojilov - 2.0.0-0 - [cli] Improved UI - [cli] Removed REE and Rubinius support