15 lines
386 B
Bash
Executable file
15 lines
386 B
Bash
Executable file
#!/bin/zsh
|
|
export XDG_CONFIG_HOME=${XDG_CONFIG_HOME:-$HOME/.config}
|
|
SERVER_FILE=${XDG_CONFIG_HOME}/barrier/server
|
|
if [[ ! -e $SERVER_FILE ]] then
|
|
<<-ERROR
|
|
Service requires configuration!
|
|
Create \`${SERVER_FILE}\` containing the target server name
|
|
ERROR
|
|
exit 1
|
|
fi
|
|
source ${0:A:h:h}/import-env.zsh
|
|
import-env awesome || exit 1
|
|
|
|
exec 2>&1
|
|
exec barrierc --no-daemon $(<${SERVER_FILE})
|