diff options
author | pacien | 2017-09-07 10:03:54 +0200 |
---|---|---|
committer | pacien | 2017-09-07 10:03:54 +0200 |
commit | 577beba2156255aa3813433bd712725f57f4e853 (patch) | |
tree | 69191970b23879861333e014c8673cecd62027c4 | |
parent | 25ba35cb7704e8d6cab607cf506d246a0f529ce2 (diff) | |
download | desktop-utilities-master.tar.gz |
-rwxr-xr-x | roaming.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/roaming.sh b/roaming.sh new file mode 100755 index 0000000..17b67b3 --- /dev/null +++ b/roaming.sh | |||
@@ -0,0 +1,20 @@ | |||
1 | #!/usr/bin/env sh | ||
2 | |||
3 | set -x | ||
4 | |||
5 | case $1 in | ||
6 | "enable") | ||
7 | systemctl --user stop syncthing | ||
8 | sudo systemctl start tinc | ||
9 | ;; | ||
10 | "disable") | ||
11 | systemctl --user start syncthing | ||
12 | sudo systemctl stop tinc | ||
13 | ;; | ||
14 | *) | ||
15 | echo "Invalid action." | ||
16 | echo "Usage: $0 enable|disable" | ||
17 | exit | ||
18 | ;; | ||
19 | esac | ||
20 | |||