From 16aec06eb45aea4e9d5c127daab6ea281d88006d Mon Sep 17 00:00:00 2001 From: ivan-boikov Date: Sat, 25 Nov 2023 15:34:34 +0100 Subject: Scripts --- scripts/.local/bin/mailsync | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 scripts/.local/bin/mailsync (limited to 'scripts/.local/bin/mailsync') diff --git a/scripts/.local/bin/mailsync b/scripts/.local/bin/mailsync new file mode 100755 index 0000000..cb00bb7 --- /dev/null +++ b/scripts/.local/bin/mailsync @@ -0,0 +1,13 @@ +#!/bin/sh + +MBSYNC=$(pgrep mbsync) + +if [ -n "$MBSYNC" ]; then + echo "Already running one instance of mbsync or notmuch. Exiting..." + exit 0 +fi + +mbsync -c "$XDG_CONFIG_HOME/mbsync/config" -a + +printf "%s " "Press enter to continue" +read -- cgit v1.2.3