-
-
Save henriquemoody/3362789 to your computer and use it in GitHub Desktop.
#!/bin/sh | |
if [ "root" != "$(whoami)" ]; then | |
echo "You must run this command as root" 1>&2 | |
exit 1 | |
fi | |
set -x | |
# Download and extract | |
if [ ! -z "${1}" ]; then | |
VERSION="${1}" | |
else | |
VERSION="0.34" | |
fi | |
TARBALL="/usr/src/ArgoUML-${VERSION}.tar.gz" | |
if [ ! -f "${TARBALL}" ]; then | |
curl -L "http://argouml-downloads.tigris.org/nonav/argouml-${VERSION}/ArgoUML-${VERSION}.tar.gz" -o "${TARBALL}" | |
fi | |
tar -xzf "${TARBALL}" -C /usr/src | |
# Move and create a valid symlink | |
mv "/usr/src/argouml-${VERSION}" "/usr/local/argouml-${VERSION}" | |
ln -s "/usr/local/argouml-${VERSION}/argouml.sh" "/usr/local/bin/argouml" | |
# Desktop shortcut | |
SHORTCUT="[Desktop Entry] | |
Name=ArgoUML ${VERSION} | |
Exec=/usr/local/argouml-${VERSION}/argouml.sh | |
Icon=/usr/local/argouml-${VERSION}/icon/ArgoIcon128x128.png | |
Terminal=false | |
Type=Application | |
Encoding=UTF-8 | |
Categories=Utility;Java;Development;UML" | |
echo "${SHORTCUT}" > "/usr/share/applications/argouml-${VERSION}.desktop" | |
set +x | |
echo "Finish!" | |
exit 0 |
Very nice! Thank you. It worked perfectly on Linux 17.10!
Anda excelente! gracias. (ubuntu 16.04)
Nice! Thank you for sharing. It worked on ubuntu 18.04.
it works perfectly on debian 9. Thanks.
Cool ! Thanks ! It worked on ubuntu 18.04.
Thanks You
Thanks 👍
how do I use this code? terminal?
@RobbyGold run: bash ArgoUML.sh
Can anyone please explain how to use/run this ubuntu 18? I am beginner and i have no idea how to run this..?
- Download the file above (or copy and past it in a file and store it as
ArgoUML.sh
) - Open a terminal, open the folder where you stored the file and run:
sudo bash ArgoUML.sh
- Download the file above (or copy and past it in a file and store it as
ArgoUML.sh
)- Open a terminal, open the folder where you stored the file and run:
sudo bash ArgoUML.sh
Hi @hamidgasmi, I followed the instruction. seen the below but the application not launching when run ArgoUML.sh
in terminal
Here is the updated script. The argoUml download URL has changed
#!/bin/sh
if [ "root" != "$(whoami)" ]; then
echo "You must run this command as root" 1>&2
exit 1
fi
set -x
# Download and extract
if [ ! -z "${1}" ]; then
VERSION="${1}"
else
VERSION="0.35.1"
fi
TARBALL="/usr/src/ArgoUML-${VERSION}.tar.gz"
if [ ! -f "${TARBALL}" ]; then
curl -L "https://github.com/argouml-tigris-org/argouml/releases/download/VERSION_$( echo ${VERSION} | tr '.' '_' )/ArgoUML-${VERSION}.tar.gz" -o "${TARBALL}"
fi
tar -xzf "${TARBALL}" -C /usr/src
# Move and create a valid symlink
mv "/usr/src/argouml-${VERSION}" "/usr/local/argouml-${VERSION}"
ln -s "/usr/local/argouml-${VERSION}/argouml.sh" "/usr/local/bin/argouml"
# Desktop shortcut
SHORTCUT="[Desktop Entry]
Name=ArgoUML ${VERSION}
Exec=/usr/local/argouml-${VERSION}/argouml.sh
Icon=/usr/local/argouml-${VERSION}/icon/ArgoIcon128x128.png
Terminal=false
Type=Application
Encoding=UTF-8
Categories=Utility;Java;Development;UML"
echo "${SHORTCUT}" > "/usr/share/applications/argouml-${VERSION}.desktop"
set +x
echo "Finish!"
exit 0
Here is the updated script. The argoUml download URL has changed
#!/bin/sh if [ "root" != "$(whoami)" ]; then echo "You must run this command as root" 1>&2 exit 1 fi set -x # Download and extract if [ ! -z "${1}" ]; then VERSION="${1}" else VERSION="0.35.1" fi TARBALL="/usr/src/ArgoUML-${VERSION}.tar.gz" if [ ! -f "${TARBALL}" ]; then curl -L "https://github.com/argouml-tigris-org/argouml/releases/download/VERSION_$( echo ${VERSION} | tr '.' '_' )/ArgoUML-${VERSION}.tar.gz" -o "${TARBALL}" fi tar -xzf "${TARBALL}" -C /usr/src # Move and create a valid symlink mv "/usr/src/argouml-${VERSION}" "/usr/local/argouml-${VERSION}" ln -s "/usr/local/argouml-${VERSION}/argouml.sh" "/usr/local/bin/argouml" # Desktop shortcut SHORTCUT="[Desktop Entry] Name=ArgoUML ${VERSION} Exec=/usr/local/argouml-${VERSION}/argouml.sh Icon=/usr/local/argouml-${VERSION}/icon/ArgoIcon128x128.png Terminal=false Type=Application Encoding=UTF-8 Categories=Utility;Java;Development;UML" echo "${SHORTCUT}" > "/usr/share/applications/argouml-${VERSION}.desktop" set +x echo "Finish!" exit 0
and how can i run it
Works great on ubuntu 20.04. Thanks!
how to remove it ?? on ubuntu 21.04
Works great on ubuntu 20.04. Thanks!
hey, how to remove it ?
work well on ubuntu 18.04 thank you for sharing
Thank you!
Personal, Just use the code below:
#!/bin/sh
if [ "root" != "$(whoami)" ]; then
echo "You must run this command as root" 1>&2
exit 1
fi
set -x
# Download and extract
if [ ! -z "${1}" ]; then
VERSION="${1}"
else
VERSION="0.35.1"
fi
TARBALL="/usr/src/ArgoUML-${VERSION}.tar.gz"
if [ ! -f "${TARBALL}" ]; then
curl -L "https://github.com/argouml-tigris-org/argouml/releases/download/VERSION_$( echo ${VERSION} | tr '.' '_' )/ArgoUML-${VERSION}.tar.gz" -o "${TARBALL}"
fi
tar -xzf "${TARBALL}" -C /usr/src
# Move and create a valid symlink
mv "/usr/src/argouml-${VERSION}" "/usr/local/argouml-${VERSION}"
ln -s "/usr/local/argouml-${VERSION}/argouml.sh" "/usr/local/bin/argouml"
# Desktop shortcut
SHORTCUT="[Desktop Entry]
Name=ArgoUML ${VERSION}
Exec=/usr/local/argouml-${VERSION}/argouml.sh
Icon=/usr/local/argouml-${VERSION}/icon/ArgoIcon128x128.png
Terminal=false
Type=Application
Encoding=UTF-8
Categories=Utility;Java;Development;UML"
echo "${SHORTCUT}" > "/usr/share/applications/argouml-${VERSION}.desktop"
set +x
echo "Finish!"
exit 0
later:
(copy and paste into a file and store as ArgoUML.sh)
Open a terminal, open the folder where you stored the file and run: sudo bash ArgoUML.sh
Like a charm in Fedora23