Open chung-leong opened 5 months ago
Fedora also uses .bashrc
instead of .profile
.
Thanks for taking the time to make this issue. I'll look into it and hopefully have a fix out soon.
looked into it, you're probably using wget2, which fedora uses by default instead of wget. wget2 doesnt have the --show-progress flag, causing the script to crash. As a quickfix you could tweak the install script a bit to use curl instead of wget
Nice find! I think the better solution would be to add a check on the version of wget
and if the progress flag isn't supported we can run the equivalent on wget2
or use Curl if it's installed.
@chung-leong Can you try the #92?
curl https://raw.githubusercontent.com/isFakeAccount/zvm/master/install.sh | bash
I tested it on https://github.com/isFakeAccount/zvm/actions/runs/9982103634. Seems to work.
@i-am-wololo Does fedora alias wget to wget2?
@isFakeAccount Yes it does alias it like that. ll /usr/bin/wget lrwxrwxrwx. 1 root root 5 Jul 2 02:00 /usr/bin/wget -> wget2
Right now i usually download the script and then remove the show-progress flags but that obviously still is a little extra work on each upgrade.
Fedora also uses
.bashrc
instead of.profile
.
I think here it would make more sense to provide a flag to set the config file. I will usually use my .zshenv for these kind of configs.
That would make sense. Some kind of automatic determination would be good too, with the flag as a backup in case it couldn't make a decision or the user knows what they want.
I realize I have a blind spot as I develop on Debian and test on SUSE.
I was just messing around with the script to get it to work and the easiest fix would be to just have the verbose flag (as this is the same in each wget version but --show-pogress turns into --force-progress). But I suspect you want a more sophisticated option than this.
You could have a big conditional to cover for it but it mean that red text saying " Unknown option 'show-progress' " but it works.
wget --quiet --show-progress --max-redirect 5 -O zvm.tar "https://github.com/tristanisham/zvm/releases/latest/download/$1" || wget --quiet --force-progress --max-redirect 5 -O zvm.tar "https://github.com/tristanisham/zvm/releases/latest/download/$1"
Describe the bug
Desktop (please complete the following information):