---
name: "lei-rm"
section: "1"
platform: "linux"
package: "lei"
version: "2.1.0-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/lei-rm"
---

# lei-rm(1)

unindex a message in lei/store

## NAME

lei-rm - unindex a message in lei/store

## SYNOPSIS

lei rm \[OPTIONS\] (-\|--stdin)

lei rm \[OPTIONS\] LOCATION

## DESCRIPTION

Removes message(s) and associated private metadata from lei/store indices.  It does not affect messages stored in externals, so it's still possible to get "removed" messages from externals in lei-q search results.

This does not remove the message from underlying git storage nor does it remove messages from Maildir/mbox/IMAP/etc. sources.

## OPTIONS

- \-

  - \--stdin

  Read input from standard input.  This is the default if standard input is a pipe or regular file and there are no arguments on the command-line.

- \-F MAIL\_FORMAT

  - \--in-format=MAIL\_FORMAT

  Message input format: `"eml"`, `"mboxrd"`, `"mboxcl2"`, `"mboxcl"`, or `"mboxo"` when reading from stdin or using one of the mbox variants.

  Not necessary when using an IMAP URL, NNTP URL or Maildir.

  Default: `"eml"` when reading from stdin or if the file suffix ends in `".patch"` or `".eml"`.

- \--lock=METHOD

  [**mbox**(5)](/mbox/5.md) locking method(s) to use: `"dotlock"`, `"fcntl"`, `"flock"` or `"none"`.

  Default: fcntl,dotlock

- \-q

  - \--quiet

  Suppress feedback messages.

## CONTACT

Feedback welcome via plain-text mail to \<mailto:meta@public-inbox.org\>

The mail archives are hosted at \<https://public-inbox.org/meta/\> and \<http://4uok3hntl7oi7b4uf4rtfwefqeexfzil2w6kgk2jn5z2f764irre7byd.onion/meta/\>

## COPYRIGHT

Copyright all contributors \<mailto:meta@public-inbox.org\>

License: AGPL-3.0+ \<https://www.gnu.org/licenses/agpl-3.0.txt\>

## SEE ALSO

[**lei-store-format**(5)](/lei-store-format/5.md)
