#!/bin/sh up () { transmission-remote --exit sudo wg-quick up $1 exit } down () { sudo wg-quick down $1 start-program transmission-daemon exit } [ "$2" = "up" ] && up $1 [ "$2" = "down" ] && down $1 exit 1