SHARE
TWEET

Upgrade vector-im/riot-web

u1-liquid Sep 7th, 2019 102 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/bin/bash
  2.  
  3. pushd /home/matrix/riot > /dev/null
  4.  
  5. LATEST=$(curl -sSL https://api.github.com/repos/vector-im/riot-web/releases/latest | grep "browser_download_url" | grep -o -E "https://github.com/(.+)\.\w+" | grep -E "\.tar\.gz$")
  6. curl -sSL -o latest $LATEST.asc
  7. diff current latest
  8. if [[ $? -eq 0 ]]; then
  9.   rm latest
  10. else
  11.   mv -f latest current
  12.   curl -sSL -o riot.tar.gz $LATEST
  13.   tar xvzf riot.tar.gz
  14.   rm -rf live riot.tar.gz
  15.   mv riot-* live
  16.   ln -s /home/matrix/riot/config.json live/config.json
  17. fi
  18.  
  19. popd > /dev/null
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top