Closed nfitch closed 10 years ago
[root@45d5220b-8725-c903-d883-f010921372a8 /var/tmp]# cat modpacks%5EUltimate%5Eultimate%5EUltimate_Server.zip
An error has occured and CreeperHost is unable to find this file "modpacks/Ultimate/ultimate/Ultimate_Server.zip".
The error says it all. We may have to find an alternate location to download it from.
This is the url I got from the script, then from the website:
#Script:
http://www.creeperrepo.net/direct/FTB2/6b87107415174d7b47c0ca1a1d198061/modpacks%5EUlctimate%5Eultimate%5EUltimate_Server.zip
#Website:
http://www.creeperrepo.net/direct/FTB2/6b87107415174d7b47c0ca1a1d198061/modpacks%5EUltimate%5E1_1_2%5EUltimate_Server.zip
What should be "1_1_2" is "ultimate" in the bad url.
The problem is shown by this simple script:
nate:~ nfitch$ cat ftb_version.sh
SERVER_FLAVOR=ftb-ultimate
SERVER_VERSION=${SERVER_FLAVOR#*-}
[[ ${SERVER_VERSION} == ${SERVER_FLAVOR} ]] && unset SERVER_VERSION
: ${SERVER_VERSION:=1.1.2}
SERVER_URL="http://www.creeperrepo.net/direct/FTB2/6b87107415174d7b47c0ca1a1d198061/modpacks%5EUltimate%5E${SERVER_VERSION//\./_}%5EUltimate_Server.zip"
echo $SERVER_VERSION
echo $SERVER_URL
nate:~ nfitch$ ./ftb_version.sh
ultimate
http://www.creeperrepo.net/direct/FTB2/6b87107415174d7b47c0ca1a1d198061/modpacks%5EUltimate%5Eultimate%5EUltimate_Server.zip
Looks like we're parsing the version by looking at everything after a '-'. Since ftb-ultimate has a '-' in it, it's parsing "ultimate" as the version. I think I'll fix it so that it's ftb_ultimate rather than ftb-ultimate, leaving the '-' for the version.