Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tmux-plugins/tmux-maildir-counter
Plugin that counts files on a specific mail directory
https://github.com/tmux-plugins/tmux-maildir-counter
Last synced: 3 months ago
JSON representation
Plugin that counts files on a specific mail directory
- Host: GitHub
- URL: https://github.com/tmux-plugins/tmux-maildir-counter
- Owner: tmux-plugins
- License: mit
- Created: 2015-08-21T17:27:25.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2022-03-14T01:54:07.000Z (over 2 years ago)
- Last Synced: 2024-04-18T15:08:16.264Z (7 months ago)
- Language: Shell
- Size: 18.6 KB
- Stars: 32
- Watchers: 3
- Forks: 6
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-tmux - tmux-maildir-counter
README
# Tmux maildir counter
**NOTE:** This project is no longer in active development. Bugs and
features requests won't get implemented by the project maintainers.
We still welcome discussions and community pull requests, though.---
Plugin that counts files on a specific mail directory.
If you use [offlineimap](http://offlineimap.org/) to synchronize your emails with your computer,
you can use this plugin to count how many emails you have in a specific folder and display in your tmux
left or right status bar.Shows how many unread emails I have in both my personal and work accounts:
![prefix_off](screenshots/maildir_counter.png)### Usage
Add the list of folders you want to count to your `tmux.conf`. All folders must be separated by `|`.
```tmux.conf
set -g @maildir_counters '~/Mail/Personal/INBOX/new|~/Mail/Work/INBOX/new'
```Then, add the `maildir_counter` to your left/right status bar where `N` is the index of the folder you want to show.
```tmux.conf
set -g status-right 'Personal: #{maildir_counter_1}, Work: #{maildir_counter_2} | %a %Y-%m-%d %H:%M'
```If you want to get unread count, pass only the path of the IMAP folder and plugin will check `cur` and `new` subfolders, filter them and present any unread mail. Omit trailing slash.
```tmux.conf
set -g @maildir_counters '~/Mail/Personal/INBOX/new|~/Mail/Work/INBOX'
```Then, add the `maildir_unread_counter` variable and set it to `yes`:
```tmux.conf
set -g @maildir_unread_counter 'yes'
```### Installation with Tmux Plugin Manager (recommended)
Add plugin to the list of TPM plugins:
```tmux.conf
set -g @plugin 'tmux-plugins/tmux-maildir-counter'
```Press prefix + I to install it.
### Manual Installation
Clone the repo:
```bash
$ git clone https://github.com/tmux-plugins/tmux-maildir-counter.git ~/clone/path
```Add this line to your .tmux.conf:
```tmux.conf
run-shell ~/clone/path/tmux-maildir-counter.tmux
```Reload TMUX environment with:
```bash
$ tmux source-file ~/.tmux.conf
```### License
[MIT](LICENSE)