Created
February 8, 2018 19:06
-
-
Save FranLpz/a2c42ee09b611b1c299140d1e9552c8e to your computer and use it in GitHub Desktop.
Script for install robomongo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Enter /opt folder (common folder for user installed programs) | |
# This script assumes you have proper permissions on /opt | |
cd /opt | |
# Download robomongo | |
wget https://download.robomongo.org/1.1.1/linux/robo3t-1.1.1-linux-x86_64-c93c6b0.tar.gz -O robomongo.tar.gz | |
# Delete Old robomongo if exists. | |
if [ -d robomongo/ ]; then | |
rm -rf robomongo | |
fi | |
# Extract the RoboMongo into /opt directory | |
tar -xvzf robomongo.tar.gz -C robomongo | |
# Remove tar.gz | |
rm robomongo.tar.gz | |
# Add robomongo to PATH | |
echo "export PATH=\$PATH:/opt/robomongo" >> ~/.bashrc | |
source ~/.bashrc | |
# Download robomongo launcher icon | |
wget https://i.pinimg.com/originals/93/df/b5/93dfb5ea58d8724795afda15fc703f19.png -O robomongo/icon.png | |
# Create desktop entry | |
sudo touch /usr/share/applications/robomongo.desktop | |
# copy the following contents into robomongo.desktop file: | |
echo " | |
[Desktop Entry] | |
Name=Robomongo | |
Comment=GUI Tool for MongoDB | |
Exec=/opt/robomongo/bin/robo3t | |
Icon=/opt/robomongo/icon.png | |
Terminal=false | |
Type=Application | |
Encoding=UTF-8 | |
Categories=Utility;Development;" | sudo tee -a /usr/share/applications/robomongo.desktop >/dev/null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment