#!/bin/bash

root=$(dirname $0)
if [ "${root#./}" != "${root}" ]; then
  root="$(pwd)/${root#./}"
fi
if [ "${root#/}" = "${root}" ]; then
  if [ "${root}" = "." ]; then
    root="$(pwd)";
  else 
    root="$(pwd)/${root}"
  fi
fi

source=$1
target=$2
java -jar ${root}/pdfextract-cli-M3-SNAPSHOT.jar --arc ${source} ${target}
