#!/bin/bash

function error {
	echo -e "\\e[91m$1\\e[39m"
	exit
}

cd ~/.local/share/
wget https://github.com/processing/processing/releases/download/processing-0270-3.5.4/processing-3.5.4-linux64.tgz || error "failed to download"
tar -xf processing*.tgz || error "failed to extract"
rm processing*.tgz
sudo ~/.local/share/processing*/install.sh
