#!/bin/bash # # Connect to Win VMs # # A script to connect to windows machines function usage_and_exit { echo "Usage: $(basename ${0}) " exit 1 } # Exit if we have an incorrect number of arguments if [ ${#} -ne 1 ]; then usage_and_exit fi menu=$(gopass ls --flat | rofi -dmenu -p "gopass") xfreerdp +clipboard /u:snarbutas /v:"${1}" /drive:home,/home/snarbutas/temp/smb /p:"$(gopass $menu)" /size:1600x1200 /sec:rdp