From 5e8f1b27e68ed74fd185264ef54f9fdda93fa16f Mon Sep 17 00:00:00 2001 From: Tobias Hopp Date: Mon, 15 Mar 2021 10:57:44 +0100 Subject: [PATCH] Add restarter Took 2 minutes --- restart.sh | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 restart.sh diff --git a/restart.sh b/restart.sh new file mode 100644 index 0000000..a4a34ea --- /dev/null +++ b/restart.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash + +cd /home/tobiash/Woam-Antispam-Bot/ || exit +tmux kill-session -t WoamBot +git pull --quiet + +tmux new-session -d -s WoamBot +tmux send-keys -t WoamBot:0 "cd /home/tobiash/Woam-Antispam-Bot/ && clear && node bot.js" C-m