go-nv / goenv

:blue_car: Like pyenv and rbenv, but for Go.

Home Page:https://github.com/go-nv/goenv

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add options to remove download progress bar from output

ArcticSnowman opened this issue · comments

HI we use goenv manage the GO versions available to our CI/CD environment. We automate the installation of GO versions from a job. The log gets very cluttered with the download progress bar.

It would be nice if there was an option that would disable the display of the progress bar.
Something like

--noprogess

Or maybe

--quiet

Looing to see how easy it would be I did find code in build-go to disable progress:

  if [[ $DISABLE_PROGRESS_BAR == "true" ]]; then
    options="-s"
  else
    options="--progress-bar"
  fi

SO setting

~$ DISABLE_PROGRESS_BAR=true goenv install 1.19.5 -s
Downloading go1.19.5.linux-amd64.tar.gz...
-> go1.19.5.linux-amd64.tar.gz
Installing Go Linux 64bit 1.19.5...
Installed Go Linux 64bit 1.19.5 to /home/sarnott/.goenv/versions/1.19.5

@ChronosMasterOfAllTime - Thanks Muchly

You're very welcome!