Skip to content

Instantly share code, notes, and snippets.

@IlyaZha
Forked from almirb/Install_Phpstorm.sh
Last active October 2, 2018 16:05
Show Gist options
  • Save IlyaZha/e78ba4abaac8463b46df55ff8b8238c6 to your computer and use it in GitHub Desktop.
Save IlyaZha/e78ba4abaac8463b46df55ff8b8238c6 to your computer and use it in GitHub Desktop.
Update webstorm on Ubuntu linux.
#!/bin/bash -e
# Original credits to theodorosploumis
# IMPORTANT. My webstorm installation exists on /opt/webstorm.
if [ "$(whoami)" != "root" ]
then
echo "Sorry, you are not root."
exit 1
fi
# Remove old webstorm
echo "Removing old WebStorm"
rm -rf /opt/webstorm
# Download file from url
echo "Downloading WebStorm to /tmp"
wget -O /tmp/webstorm.tar.gz "https://data.services.jetbrains.com/products/download?code=WS&platform=linux" --no-check-certificate
# Unpacking file
tar -xzf /tmp/webstorm.tar.gz -C /tmp
rm /tmp/webstorm.tar.gz
# Copy new Webstorm
echo "Copying new WebStorm"
mv /tmp/WebStorm* /opt/webstorm
# Finish
echo "New WebStorm has been installed!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment