summaryrefslogtreecommitdiff
path: root/src/rpc.main.bash
blob: 21dc071c7a5240dadef9a50a8bd378cba27e0b5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/bash
set -e
set -o pipefail
case "$0" in
        [^/]* ) PATH=$(realpath -e "$(dirname "$BASH_SOURCE")"):$PATH ;;
esac
source rpc.bash

gudge()
{
        echo "Hello, ${REPLY@Q}."
        topic=${*@Q}
        echo "Don't argue with me about ${topic:-punctuation}."
}
fudge()
{
        read -p "[$(hostname)] Name? " && gudge "$@"
        exit
}
with_ssh_options -4 -- \
        remote_run_function \
                fudge "$@"