File: poll.sh

package info (click to toggle)
astroidmail 0.16%2B20240629-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 5,140 kB
  • sloc: cpp: 21,133; ansic: 1,619; python: 93; sh: 73; makefile: 11
file content (23 lines) | stat: -rwxr-xr-x 664 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env bash
#
# poll.sh - An example poll script for astroid.
#
# Intended to be run by astroid. See the following link for more information:
# https://github.com/astroidmail/astroid/wiki/Polling
#
# In particular, in order for this script to be run by astroid, it needs to be
# located at ~/.config/astroid/poll.sh
#

# Exit as soon as one of the commands fail.
set -e

# Fetch new mail.
offlineimap

# Import new mail into the notmuch database.
notmuch new

# Here you can process the mail in any way you see fit. See the following link
# for examples:
# https://github.com/astroidmail/astroid/wiki/Advanced-Polling-and-Processing-mail#automatic-tagging