#!/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
}

#PACKAGES FOUND IN: https://launchpad.net/~cartes/+archive/ubuntu/ppa/+packages

rm -f ~/drawing.deb
wget -O ~/drawing.deb "https://launchpad.net/~cartes/+archive/ubuntu/drawing/+files/drawing_0.8.3-0ubuntu1~hirsute_arm64.deb" || error "Failed to download drawing.deb"

sudo apt install -yf ~/drawing.deb || error "APT failed to install drawing.deb"
rm -f ~/drawing.deb
