Deal with Riot -> Element rename

This commit is contained in:
Lucas 2020-10-03 16:05:14 +00:00
parent 79a12e7ff3
commit ce2502c113
1 changed files with 4 additions and 3 deletions

View File

@ -27,13 +27,14 @@ isversion()
printf "%s\n" "$*" | grep -Eq "^v[0-9]+\.[0-9]+\.[0-9]+$"
}
[ -n "${RIOT_WEB_UI_DIR:-}" ] || err "environment var RIOT_WEB_UI_DIR unset"
[ -n "${ELEMENT_WEB_UI_DIR:-}" ] ||
err "environment var ELEMENT_WEB_UI_DIR unset"
[ $# -eq 1 ] && isversion "$1" || usage
ver=$1
GH_BASE_URL=https://github.com/vector-im/riot-web/releases/download
GH_BASE_URL=https://github.com/vector-im/element-web/releases/download
cd "$RIOT_WEB_UI_DIR" || err "can't cd to web UI directory"
cd "$ELEMENT_WEB_UI_DIR" || err "can't cd to web UI directory"
ftp -o - "$GH_BASE_URL/$ver/riot-$ver.tar.gz" | pax -rz ||
err "can't fetch and extract release"
rm -f riot && ln -s "riot-$ver" riot ||