#!/bin/sh
OPENVPN_CONF_DIR="/var/mobile/Library/OpenVPN"

if [ "$1" != "" ] ; then
	echo "Making $1 the default OpenVPN configuration" 
	cp "$OVPN/$1.ovpn" "$OVPN/client.ovpn"
else
	echo "Usage:   $0 [configuration to become default]"
	echo
	echo "Example: configuration named \"example.ovpn\" in directory \"$OPENVPN_CONF_DIR\""
	echo "         $0 example"
	echo
	echo "NOTE: all configuration files MUST have the \".ovpn\" extension"
fi
