ragdoll-mail 0.11.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 erict16
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,59 @@
1
+ Metadata-Version: 2.4
2
+ Name: ragdoll-mail
3
+ Version: 0.11.0
4
+ Summary: Your IMAP mailbox from the terminal, for you and AI agents: local search, reply drafts, checks before sending
5
+ Author: Eric Tan
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://erict16.github.io/ragdoll-mail/
8
+ Project-URL: Source, https://github.com/erict16/ragdoll-mail
9
+ Project-URL: Releases, https://github.com/erict16/ragdoll-mail/releases
10
+ Keywords: email,imap,mail client,full-text search,exmail,cli,ai agent
11
+ Classifier: Environment :: Console
12
+ Classifier: Intended Audience :: End Users/Desktop
13
+ Classifier: Operating System :: POSIX :: Linux
14
+ Classifier: Operating System :: MacOS
15
+ Classifier: Operating System :: Microsoft :: Windows
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Topic :: Communications :: Email :: Email Clients (MUA)
18
+ Requires-Python: >=3.10
19
+ Description-Content-Type: text/markdown
20
+ License-File: LICENSE
21
+ Dynamic: license-file
22
+
23
+ # ragdoll: your mailbox from the terminal, for you and your AI agent
24
+
25
+ `ragdoll` is the command line of [Ragdoll Mail](https://erict16.github.io/ragdoll-mail/), a free, open-source mail app for Mac and Windows. It works with any IMAP mailbox. You can search, read whole threads, write reply drafts, check them and send them. Claude Code, Codex or any other agent that runs commands can do the same, so the agent and you work on the same mailbox.
26
+
27
+ ```console
28
+ you › Reply to Lucas and tell him the first batch ships on the 4th.
29
+
30
+ agent $ ragdoll search Lucas "PO-1234" --json
31
+ agent $ ragdoll draft --reply inbox:312 --body reply.html
32
+ agent $ ragdoll check drafts:14 --reply
33
+ CHECK OK
34
+ agent › The draft is in your Drafts folder. Shall I send it?
35
+ ```
36
+
37
+ Search runs on a local SQLite index, not on the mail server. On a real inbox of 5,044 mails, a search took 6 ms locally. The same search through the server took about a second, because the CLI had to sign in again first.
38
+
39
+ Drafts are saved in your mailbox's real Drafts folder, with your signature and the quoted thread. `check` catches an empty subject, "attached" with nothing attached, or a `[Name]` left in the text. `send` needs `--yes`, and the same draft is never sent twice. There is no API key, no OAuth app and no quota: ragdoll talks plain IMAP and SMTP to your own server.
40
+
41
+ ## Install
42
+
43
+ ```sh
44
+ pipx install ragdoll-mail
45
+ ```
46
+
47
+ Python 3.10 or newer; it uses only the standard library. Update with `pipx upgrade ragdoll-mail`.
48
+
49
+ On a Mac you can also use Homebrew (`brew tap erict16/tap`, `brew trust erict16/tap`, `brew install ragdoll`), or get the desktop app, which comes with the command.
50
+
51
+ ## Set up
52
+
53
+ 1. Copy [config.example.json](https://github.com/erict16/ragdoll-mail/blob/main/config.example.json) to `~/.config/ragdoll-mail/config.json` and fill in your mailbox.
54
+ 2. Put the IMAP app password in the environment variable that `password_env` names, or sign in once in the desktop app, which keeps it in the system keychain. ragdoll never prints it.
55
+ 3. Build the index once: `ragdoll sync --bodies`. Later commands fetch only what is new.
56
+
57
+ Every command, and a paragraph to put in your `CLAUDE.md` or `AGENTS.md`, is in [the command-line guide](https://github.com/erict16/ragdoll-mail/blob/main/docs/command-line.md).
58
+
59
+ MIT licence. Source: [github.com/erict16/ragdoll-mail](https://github.com/erict16/ragdoll-mail).
@@ -0,0 +1,169 @@
1
+ <p align="center"><img src="assets/icon-256.png" width="112" alt="Ragdoll Mail icon"></p>
2
+
3
+ <h1 align="center">Ragdoll Mail</h1>
4
+
5
+ <p align="center"><b>The free mail app your AI agent can use.<br>A desktop app for Mac and Windows with a command line built in: Claude Code, Codex and other agents can search your mail, write replies and send them once you say yes.</b></p>
6
+
7
+ <p align="center">Works with Tencent Exmail (腾讯企业邮箱), QQ Mail, 163, Gmail, iCloud, Fastmail and any other IMAP mailbox.</p>
8
+
9
+ <p align="center">
10
+ <a href="https://github.com/erict16/ragdoll-mail/releases/latest"><img src="https://img.shields.io/github/v/release/erict16/ragdoll-mail" alt="Latest release"></a>
11
+ <a href="https://github.com/erict16/ragdoll-mail/actions/workflows/build.yml"><img src="https://img.shields.io/github/actions/workflow/status/erict16/ragdoll-mail/build.yml?label=tests" alt="Tests"></a>
12
+ <a href="LICENSE"><img src="https://img.shields.io/github/license/erict16/ragdoll-mail" alt="MIT license"></a>
13
+ </p>
14
+
15
+ <p align="center">
16
+ <a href="https://github.com/erict16/ragdoll-mail/releases/latest/download/ragdoll-mail-mac.dmg"><b>Download for Mac</b></a> ·
17
+ <a href="https://github.com/erict16/ragdoll-mail/releases/latest/download/ragdoll-mail-windows.zip"><b>Download for Windows</b></a> ·
18
+ <a href="https://erict16.github.io/ragdoll-mail/"><b>Website</b></a> ·
19
+ <a href="README.zh-CN.md"><b>简体中文</b></a>
20
+ </p>
21
+
22
+ <p align="center"><img src="docs/demo.gif" width="860" alt="Ragdoll Mail on a Mac: an AI agent in a terminal writes a reply with the ragdoll command, the draft opens in the app, the send is undone and set for tomorrow, and search finds mail as you type"></p>
23
+
24
+ ## What is Ragdoll Mail?
25
+
26
+ Ragdoll Mail is a mail app for Mac and Windows, like Apple Mail or Outlook, with one difference: it comes with `ragdoll`, a command line that AI agents such as Claude Code and Codex can use. Your agent can search your mail, read whole conversations and write replies. Each reply is saved as a draft. The agent sends it when you say yes in the chat, or you open it in the app and press Send yourself.
27
+
28
+ Search runs on your own computer. Ragdoll Mail keeps a full-text index of your mailbox in SQLite, so a search takes milliseconds instead of a trip to the mail server, and it still works offline. That matters on mailboxes such as Tencent Exmail, whose own search sends back the whole folder whatever you type.
29
+
30
+ You sign in with the mailbox you already have. Nothing moves and nothing changes: your phone and your other mail apps keep working as before.
31
+
32
+ ## Why you may like it
33
+
34
+ - **Search that finds the mail.** Type a name, an order number, or a few words you remember from the text. Results show while you type. Chinese, Japanese and Korean work too. So does search with no internet.
35
+ - **Your mail stays with you.** The app talks only to your own mail server. No other company sits in between to read or keep your mail. Your password goes into the system's own password store (Keychain on Mac, Credential Manager on Windows).
36
+ - **Hard to send a mistake.** After you press Send you have up to 30 seconds to take the mail back. The app also stops you when you wrote "attached" but attached nothing, when the subject is empty, or when `[Name]` is still in the text.
37
+ - **Send later.** Write now. Send this evening, tomorrow morning, or at any time you pick.
38
+ - **Good with Chinese mail.** Names and file names from older Chinese mail systems show as they should, not as broken characters.
39
+ - **Free.** No ads, no subscription, no account to make with us. The code is open, so anyone can check what it does.
40
+
41
+ ## Start in two minutes
42
+
43
+ 1. **Download** the app from the [latest release](https://github.com/erict16/ragdoll-mail/releases/latest):
44
+ - Mac (M1 or newer): `ragdoll-mail-mac.dmg`
45
+ - Windows 10 or 11: `ragdoll-mail-windows.zip`
46
+
47
+ Or, on a Mac with [Homebrew](https://brew.sh) (this also installs the `ragdoll` command):
48
+ ```sh
49
+ brew tap erict16/tap
50
+ brew trust erict16/tap
51
+ brew install --cask ragdoll-mail
52
+ ```
53
+ 2. **Open it.** We have not paid Apple or Microsoft for a signature yet, so the system asks once:
54
+ - Mac: when macOS says it could not check the app, open **System Settings → Privacy & Security**, scroll down and press **Open Anyway**. (On older macOS: right-click the app and choose **Open**.)
55
+ - Windows: choose **More info**, then **Run anyway**.
56
+ 3. **Sign in** with your mail address and password. For the mailboxes named above, and for company addresses on Tencent Exmail, Google Workspace, Alibaba or NetEase mail, the app fills in the server settings by itself. Using Exmail? See the [Exmail setup guide](https://erict16.github.io/ragdoll-mail/exmail/).
57
+
58
+ The first time, the app reads your mailbox. For a big mailbox this takes a few minutes. You can read and write mail while it works.
59
+
60
+ > **Which password?** Many mailboxes want a special password for mail apps, not the one you use on the website. Tencent Exmail calls it 客户端专用密码. QQ Mail and 163 call it 授权码. Gmail, iCloud and Fastmail call it an app password. You make it in the settings of your mailbox's website.
61
+
62
+ ## What it can do
63
+
64
+ **Read**
65
+ - A whole conversation on one page, with the newest mail on top. Old quoted text folds away.
66
+ - Click a picture to see it large. Save one attachment, or all of them at once.
67
+ - Hold the pointer on a link to see where it goes before you click.
68
+ - A meeting invitation shows what, when and where, with a button to add it to your calendar.
69
+ - Newsletters get an **Unsubscribe** link beside the sender. One click, and they stop.
70
+
71
+ **Find**
72
+ - Press ⌘K (Mac) or Ctrl+K (Windows) and type. Search looks at the subject, the people, the text and the names of attached files.
73
+ - Narrow it down with `from:jane`, `is:unread`, `has:attachment` or `in:sent`.
74
+ - Show only unread mail, starred mail, mail with attachments, or mail from one person.
75
+
76
+ **Write**
77
+ - Fonts, sizes, bold, lists and links. Text pasted from Word or a web page keeps its look.
78
+ - Your signature goes under every mail by itself.
79
+ - A reply or a forward keeps the earlier mails and their pictures.
80
+ - Undo send, and send later.
81
+
82
+ **Keep order**
83
+ - All folders of your mailbox are in the sidebar. Make your own, and drag mail into them.
84
+ - Star, archive, delete or move one mail or many at once. Right-click a mail for the same actions.
85
+ - Mark a whole folder as read with one click.
86
+ - A short note tells you when new mail comes in.
87
+
88
+ **Make it yours**
89
+ - Light or dark.
90
+ - English, 简体中文, 繁體中文, 日本語, 한국어, Español, Français, Deutsch.
91
+ - Bigger or smaller text.
92
+ - A key for everything: **C** new mail, **R** reply, **E** archive. Press **?** to see them all.
93
+
94
+ ## Screenshots
95
+
96
+ <table>
97
+ <tr>
98
+ <td><img src="docs/hero-light.png" alt="Ragdoll Mail showing the inbox and an open conversation with attachments"></td>
99
+ <td><img src="docs/search-light.png" alt="Searching the mailbox in Ragdoll Mail: results while you type"></td>
100
+ </tr>
101
+ <tr>
102
+ <td><img src="docs/compose-light.png" alt="Writing a mail in Ragdoll Mail with fonts, lists and a signature"></td>
103
+ <td><img src="docs/hero-dark.png" alt="Ragdoll Mail in dark mode"></td>
104
+ </tr>
105
+ </table>
106
+
107
+ ## How it compares
108
+
109
+ | | **Ragdoll Mail** | Apple Mail | Outlook (new) | Thunderbird | Foxmail | Spark |
110
+ |---|:---:|:---:|:---:|:---:|:---:|:---:|
111
+ | Price | free | free | free with ads, or paid | free | free | free plan; Plus and Pro are paid |
112
+ | Mac and Windows | both | Mac only | both | both | both | both |
113
+ | Mail goes straight between you and your mail server | ✅ | ✅ | a copy is kept in Microsoft's cloud | ✅ | ✅ | goes through Spark's servers |
114
+ | Open code that anyone can check | ✅ | no | no | ✅ | no | no |
115
+ | Your own AI assistant can use the mailbox | ✅ | no | no | no | no | yes, sending needs Pro |
116
+ | Phone app | no | ✅ | ✅ | Android | no | ✅ |
117
+ | Several mailboxes in one window | not yet | ✅ | ✅ | ✅ | ✅ | ✅ |
118
+
119
+ **Where Ragdoll Mail is strong:** search, privacy, the checks before a mail goes out, and Chinese mail. It is small and does one thing: mail.
120
+
121
+ **Where the others are better:** Ragdoll Mail has no phone app and no calendar, and it shows one mailbox at a time. If you need those, use one of the others, or use both: Ragdoll Mail does not change anything in your mailbox.
122
+
123
+ <sub>Compared from each product's public pages, November 2026. Is something wrong or out of date? <a href="https://github.com/erict16/ragdoll-mail/issues">Tell us</a> and we will fix it.</sub>
124
+
125
+ ## Questions and answers
126
+
127
+ **Is there a Mac or Windows app for Tencent Exmail (腾讯企业邮箱) with search that works?**
128
+ Yes, this one. We tried it on a real Exmail mailbox with 6,442 mails. The mailbox's own search gave back 4,988 mails for every word we typed, even for a word we made up. Ragdoll Mail gave back only the mails with that word, in less than a tenth of a second.
129
+
130
+ **Is my mail safe?**
131
+ Your mail is stored on your computer and on your own mail server, nowhere else. The app sends nothing to us. We have no server.
132
+
133
+ **Where is my password kept?**
134
+ In the password store of your system: Keychain on Mac, Credential Manager on Windows. It is never written into a file.
135
+
136
+ **Does it work with no internet?**
137
+ Reading and searching mail you already have: yes. Sending and getting new mail need the internet.
138
+
139
+ **Will it change my mailbox?**
140
+ No. It shows the same folders and the same mail as your mailbox's website. What you do in the app (read, move, delete, send) also shows on your phone and on the website.
141
+
142
+ **Can I try it without my mailbox?**
143
+ Yes. With the code on your computer, `python ragdoll.py app --demo` opens a made-up mailbox. Nothing is sent.
144
+
145
+ **Is it really free?**
146
+ Yes. It is open source under the MIT license.
147
+
148
+ ## For AI assistants and the command line
149
+
150
+ Ragdoll Mail also comes as a command, `ragdoll`. An AI assistant such as Claude Code or Codex can use it to find mail and write drafts for you. It can also send them: every mail first waits in your Drafts folder, is checked, and goes out only after you say yes to that draft (`ragdoll send <draft> --yes`, or `ragdoll schedule` for later). Or open the draft in the app and press Send yourself.
151
+
152
+ ```console
153
+ you › Reply to Jane and attach the signed quote.
154
+ agent $ ragdoll search Jane quote --json
155
+ agent $ ragdoll draft --reply inbox:312 --body reply.html --attach Quote.pdf
156
+ agent › The draft is in your Drafts folder. Shall I send it?
157
+ you › Yes.
158
+ agent $ ragdoll send drafts:14 --yes
159
+ ```
160
+
161
+ To get the command: **Settings → Command line → Install** in the app. To get only the command, without the app, on a Mac: `brew tap erict16/tap`, `brew trust erict16/tap`, `brew install ragdoll`. It needs no Apple signature, so macOS shows no warning. Every command and how it compares with the Gmail API: **[the command-line guide](docs/command-line.md)**.
162
+
163
+ ## Help and feedback
164
+
165
+ Found a problem, or does your mailbox not work? [Open an issue](https://github.com/erict16/ragdoll-mail/issues). Want to help with code or a translation? Read [CONTRIBUTING.md](CONTRIBUTING.md).
166
+
167
+ ## License
168
+
169
+ MIT. Icons from [Lucide](https://lucide.dev) (ISC); file-type icons from [Material Design Icons](https://pictogrammers.com/library/mdi/) (Apache-2.0).
@@ -0,0 +1,12 @@
1
+ """Old name of ragdoll.py (before 0.4.0). Kept so older copies can still update themselves
2
+ and older scripts that `import hmail` keep working. Use ragdoll.py."""
3
+ import os
4
+ import sys
5
+
6
+ sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
7
+ import ragdoll # noqa: E402
8
+
9
+ if __name__ == "__main__":
10
+ ragdoll.main()
11
+ else:
12
+ sys.modules[__name__] = ragdoll
@@ -0,0 +1,37 @@
1
+ # ragdoll: your mailbox from the terminal, for you and your AI agent
2
+
3
+ `ragdoll` is the command line of [Ragdoll Mail](https://erict16.github.io/ragdoll-mail/), a free, open-source mail app for Mac and Windows. It works with any IMAP mailbox. You can search, read whole threads, write reply drafts, check them and send them. Claude Code, Codex or any other agent that runs commands can do the same, so the agent and you work on the same mailbox.
4
+
5
+ ```console
6
+ you › Reply to Lucas and tell him the first batch ships on the 4th.
7
+
8
+ agent $ ragdoll search Lucas "PO-1234" --json
9
+ agent $ ragdoll draft --reply inbox:312 --body reply.html
10
+ agent $ ragdoll check drafts:14 --reply
11
+ CHECK OK
12
+ agent › The draft is in your Drafts folder. Shall I send it?
13
+ ```
14
+
15
+ Search runs on a local SQLite index, not on the mail server. On a real inbox of 5,044 mails, a search took 6 ms locally. The same search through the server took about a second, because the CLI had to sign in again first.
16
+
17
+ Drafts are saved in your mailbox's real Drafts folder, with your signature and the quoted thread. `check` catches an empty subject, "attached" with nothing attached, or a `[Name]` left in the text. `send` needs `--yes`, and the same draft is never sent twice. There is no API key, no OAuth app and no quota: ragdoll talks plain IMAP and SMTP to your own server.
18
+
19
+ ## Install
20
+
21
+ ```sh
22
+ pipx install ragdoll-mail
23
+ ```
24
+
25
+ Python 3.10 or newer; it uses only the standard library. Update with `pipx upgrade ragdoll-mail`.
26
+
27
+ On a Mac you can also use Homebrew (`brew tap erict16/tap`, `brew trust erict16/tap`, `brew install ragdoll`), or get the desktop app, which comes with the command.
28
+
29
+ ## Set up
30
+
31
+ 1. Copy [config.example.json](https://github.com/erict16/ragdoll-mail/blob/main/config.example.json) to `~/.config/ragdoll-mail/config.json` and fill in your mailbox.
32
+ 2. Put the IMAP app password in the environment variable that `password_env` names, or sign in once in the desktop app, which keeps it in the system keychain. ragdoll never prints it.
33
+ 3. Build the index once: `ragdoll sync --bodies`. Later commands fetch only what is new.
34
+
35
+ Every command, and a paragraph to put in your `CLAUDE.md` or `AGENTS.md`, is in [the command-line guide](https://github.com/erict16/ragdoll-mail/blob/main/docs/command-line.md).
36
+
37
+ MIT licence. Source: [github.com/erict16/ragdoll-mail](https://github.com/erict16/ragdoll-mail).
@@ -0,0 +1,34 @@
1
+ [build-system]
2
+ requires = ["setuptools>=77"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "ragdoll-mail"
7
+ version = "0.11.0"
8
+ description = "Your IMAP mailbox from the terminal, for you and AI agents: local search, reply drafts, checks before sending"
9
+ readme = "packaging/pypi.md"
10
+ requires-python = ">=3.10"
11
+ authors = [{name = "Eric Tan"}]
12
+ keywords = ["email", "imap", "mail client", "full-text search", "exmail", "cli", "ai agent"]
13
+ classifiers = [
14
+ "Environment :: Console",
15
+ "Intended Audience :: End Users/Desktop",
16
+ "Operating System :: POSIX :: Linux",
17
+ "Operating System :: MacOS",
18
+ "Operating System :: Microsoft :: Windows",
19
+ "Programming Language :: Python :: 3",
20
+ "Topic :: Communications :: Email :: Email Clients (MUA)",
21
+ ]
22
+ license = "MIT"
23
+ license-files = ["LICENSE"]
24
+
25
+ [project.urls]
26
+ Homepage = "https://erict16.github.io/ragdoll-mail/"
27
+ Source = "https://github.com/erict16/ragdoll-mail"
28
+ Releases = "https://github.com/erict16/ragdoll-mail/releases"
29
+
30
+ [project.scripts]
31
+ ragdoll = "ragdoll:main"
32
+
33
+ [tool.setuptools]
34
+ py-modules = ["ragdoll", "hmail"]