You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
503 B
Bash
18 lines
503 B
Bash
#!/bin/bash
|
|
|
|
DIRECTORY="$(dirname "$(dirname "$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )")")"
|
|
|
|
function error {
|
|
echo -e "\\e[91m$1\\e[39m"
|
|
exit 1
|
|
}
|
|
|
|
rm -f ~/freecad.deb
|
|
|
|
#download file
|
|
wget -O ~/freecad.deb https://github.com/chunky-milk/freecad-rpi/releases/download/v0.19.2/freecad_0.19.2_armhf.deb || error "Failed to download freecad.deb"
|
|
|
|
#install freecad
|
|
"${DIRECTORY}/pkg-install" "$HOME/freecad.deb" "$(dirname "$0")" || error "apt failed to install freecad.deb"
|
|
rm -f ~/freecad.deb
|