#!/bin/bash

# Crops the whitespace from png images.
# Nicked from https://askubuntu.com/a/740923

if [ $# -ne 2 ]
then
    echo "Incorrect # of parameters"
    echo "Usage: <command> input.png output.png"
    exit 1
fi


IN=$1
OUT=$2

convert $IN -border 1x1 -fuzz 15% -trim $OUT
