You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
640 B

#!/usr/bin/env bash
set -eu
CMD=""
synopsis() {
cat << EOF
Usage : `basename $0` [-h] command arg...
EOF
}
help() {
cat << EOF
`basename $0` retourne le nom du réseau courant.
`synopsis`
-h : affiche cette aide.
EOF
}
usage() {
synopsis
exit 1
}
args() {
local opt
while getopts "h" opt; do
case $opt in
h) help; exit 0;;
?) usage;;
esac
done
[ $# -ne 0 ] && usage || :
}
# Programme principal
VDN_PATH=$(readlink -f $(dirname $0)/..); . $VDN_PATH/bin/functions.sh
args "$@"
[ ! -e $HOME/.vdnrc ] && touch $HOME/.vdnrc
. $HOME/.vdnrc
echo $NETWORK_DIR