#!/bin/sh

PY=$(which python3)

if [ -z "$PY" ]; then
   PY=$(which python2)
   if [ -z "$PY" ]; then
       PY=$(which python)
   fi
fi

if [ -z "$PY" ]; then
    echo "No suitable Python runtime detected - exiting"
    exit 1
fi

bindir=$(dirname "$0")
exec "$PY" "$bindir/netconf-console.py" "$@"
