Commit df1c1b41 authored by Youness Alaoui's avatar Youness Alaoui
Browse files

Fix the ME repository getting re-downloaded if unrar doesn't exist

Basically in our case, the pre-downloaded ME repository gets ignored
when manually placed in the right place because the $sha it's checking
is the from unrar instead of being the one from the me_repository.
parent 569b4fe5
......@@ -205,9 +205,6 @@ get_and_patch_me_11 () {
local rar_filename=me_11_repository.rar
local unrar='unrar-nonfree'
if [ -f "$rar_filename" ]; then
sha=$(sha256sum "$rar_filename" | awk '{print $1}')
fi
if ! type "$unrar" &> /dev/null; then
wget -O unrar.tar.gz "$RAR_NONFREE_SOURCE_URL"
sha=$(sha256sum unrar.tar.gz | awk '{print $1}')
......@@ -221,6 +218,9 @@ get_and_patch_me_11 () {
)
unrar="`pwd`/unrar/unrar"
fi
if [ -f "$rar_filename" ]; then
sha=$(sha256sum "$rar_filename" | awk '{print $1}')
fi
if [ "$sha" != "$SKL_ME_RAR_SHA" ]; then
DIRECT_LINK=$(wget -O - "$SKL_ME_RAR_URL" 2>/dev/null | grep -o -e 'http://download.*.rar' | head -n 1)
wget -O "$rar_filename" "$DIRECT_LINK"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment