#!/bin/bash set -e fail () { echo >&2 "$0: error: $*"; exit 1; } if [ $# != 2 ]; then cat >&2 <