README
mailck is a simple mail check utility, currently supporting IMAP, designed with the following in mind:
- light: small size and resource usage
- low dependencies: low or no external dependencies
- terminal-focused: terminal usage focused (input and output) - primarily focused on usage through conky
Latest Changes
- update copyright date
- move from poetry to uv
Notices
- it does not make much sense to run this more frequently than every 10s as connecting takes ~1-2s
Features
- no configuration: install and run
- supports password or password-cmd (getting a password from an external command such as spw)
- scriptable: designed to be ran from conky, cron, or the command line
- minimal: around 250 lines of code, no dependencies
- safe: the code is clean and easy to review with no dependencies so you can easily review to see exactly what it does
Requirements
- python
Overview
mailck is a utility to check mail. The default usage simply returns a count of new (unseen) messages but you can have it return a summary (showing From, Date, and Subject) of the messages if needed. See --help and the Examples section below for more details.
We use mailck daily via conky to check several mail accounts. mailck was designed for this purpose and built because we could not find a simple, trustworthy application for this that is currently maintained. mailck has no dependencies so keeping it up-to-date is simple but we strive to keep the application functioning as designed and to address any issues quickly.
Comments / Issues / Feedback
If you find an issue, have a question, or would like a feature added please create an issue as we would be happy to hear from you.
Install
We recommend using pipx. To install:
- with pipx:
pipx install mailck - with pip:
pip install --user mailck
Usage
Using mailck is straightforward, see --help for details or the Examples section below for example usage.
By default, mailck uses LOG_LEVEL=WARNING which shows minimal extra info. If you are having issues you may want to increase application verbosity by setting the LOG_LEVEL to 'DEBUG'. You can do this by setting a LOG_LEVEL envvar (e.g. LOG_LEVEL='DEBUG' mailck --server mail.example.com --port 993 --username me@example.com --password='my-password'). Valid values for LOG_LEVEL are as follow: [CRITICAL|ERROR|WARNING|INFO|DEBUG] (suggest WARNING).
Examples
- Terminal Usage:
- basic:
mailck --server mail.example.com --port 993 --username me@example.com --password='my-password'- output:
0# indicating no new email
- output:
- basic with password-cmd:
mailck --server mail.example.com --port 993 --username me@example.com --password-cmd='spw -g mail/example@x -u'- output:
0# indicating no new email
- output:
- add prefix and suffix with password-cmd:
mailck --server mail.example.com --port 993 --username me@example.com --password-cmd='spw -g mail/example@x -u' --prefix='example@x: ' --suffix=" (new)"- output:
example@x: 0 (new)# indicating no new email
- output:
- basic with password-cmd returning message summary:
mailck --server mail.example.com --port 993 --username me@example.com --password-cmd='spw -g mail/example@x -u' -m true --prefix='Total: ' --suffix=' (new)'- output:
SA <sa@adercon.com>, 2023-12-20 20:58, Example Email 1 SA <sa@adercon.com>, 2023-12-20 20:59, Example Email 2 Total: 2 (new)
- output:
- basic:
- conky usage:
will produce something like the following in conky:conky.text = [[ ... Mail: - devops@ac: ${texeci 60 mailck --server mail.example.com --username me@example.com --password-cmd='spw -g mail/me@ac -u' --suffix=' (new)'} - dr@ac: ${texeci 60 mailck --server mail.example.com --username dr@example.com --password-cmd='spw -g mail/dr@ac -u' --suffix=' (new)'} ... ]]... Mail: - devops@ac: 2 (new) - dr@ac 0 (new) ...
Links
Metadata
Release files for mailck 0.4.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| mailck-0.4.1.tar.gz | 18.2 kB | Without provenance | Details for mailck-0.4.1.tar.gz |
Release files / mailck-0.4.1.tar.gz
| Download URL | mailck-0.4.1.tar.gz |
|---|---|
| Size | 18.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e6b617e0dd4f6b328c379e83d8389c3cb32f33d96c3638e35f0e3c93057e6a8d
|
|
BLAKE2b-256 checksum How to use checksums |
db870ba6345bdda5dfb9e893cfffc18c738588ffa2b47bb0728279e5183bb00b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.5.27
|
Security for mailck 0.4.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.