From b08e3642002e318a114b7db52b8c6561383ff93d Mon Sep 17 00:00:00 2001 From: joe Date: Thu, 2 Oct 2025 12:27:04 +0200 Subject: up --- .local/bin/fetch_mail | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to '.local') diff --git a/.local/bin/fetch_mail b/.local/bin/fetch_mail index 53967ab..9f1ca5b 100755 --- a/.local/bin/fetch_mail +++ b/.local/bin/fetch_mail @@ -11,11 +11,17 @@ sub get_new_mail my $pid; $pid = fork(); - exec('herbe', ' failed to fork') if ($pid < 0); + exec('herbe', ' failed to fork for killall') if ($pid < 0); if (not $pid) { exec('killall', 'mbsync'); } while (wait() != -1) {} + $pid = fork(); + exec('herbe', ' failed to fork for mbsync') if ($pid < 0); + if (not $pid) { + exec('mbsync', '-a'); + } + while (wait() != -1) {} return; } -- cgit v1.2.3