---
name: "lei-config"
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-config"
---

# lei-config(1)

git-config wrapper for lei configuration file

## NAME

lei-config - git-config wrapper for lei configuration file

## SYNOPSIS

lei config \<name\> \[\[\<value\>\] \[\<value-pattern\>\]\]

lei config -l \| --list

lei config -e \| --edit

## DESCRIPTION

Call [**git-config**(1)](/git-config/1.md) with `"$XDG_CONFIG_HOME/lei/config"` as the configuration file.  All `"OPTIONS"` are passed through, but those that override the configuration file are not permitted.

All `"imap"` and `"nntp"` options may be specified per-host or (if using git 2.26+) with wildcards:

```
        [imap "imap://*.onion"]
                proxy = socks5h://127.0.0.1:9050
        [nntp "nntp://example.com"]
                proxy = socks5h://127.0.0.1:1080
```

### VARIABLES

- external.\*

  Managed by [**lei-add-external**(1)](/lei-add-external/1.md) and [**lei-forget-external**(1)](/lei-forget-external/1.md)

- imap.proxy

  - nntp.proxy

  The `"socks5h://"` proxy address.  Older versions of SOCKS may be supported if there is user demand.

- imap.starttls

  - nntp.starttls

  Enable or disable STARTTLS on non-imaps:// and non-nntps:// hosts.  By default, STARTTLS is enabled if available unless connecting to a Tor .onion or localhost.

- imap.compress

  - nntp.compress

  Enable protocol-level compression.  This may be incompatible or broken with some servers.

  Note: Net::NNTP compression support is pending: \<https://rt.cpan.org/Ticket/Display.html?id=129967\>

- imap.debug

  - nntp.debug

  Enable debugging output of underlying IMAP and NNTP libraries, currently Mail::IMAPClient and Net::NNTP, respectively. If imap.proxy or nntp.proxy points to a SOCKS proxy, debugging output for IO::Socket::Socks will be enabled as well.

  Disabling imap.compress may be required for readability.

- imap.timeout

  - nntp.timeout

  The read timeout for responses.

  Default: 600 seconds (IMAP); 120 seconds (NNTP)

- imap.fetchBatchSize

  Number of full messages to fetch at once.  Larger values reduce network round trips at the cost of higher memory use, especially when retrieving large messages.

  Small responses for IMAP flags are fetched at 10000 times this value.

  Default: 1

- color.SLOT

  `"quoted"`, `"hdrdefault"`, `"status"`, `"attachment"` color slots are supported for the `"-f text"` and `"-f reply"` output formats of [**lei-lcat**(1)](/lei-lcat/1.md) and [**lei-q**(1)](/lei-q/1.md).

  Any per-project .git/config, and global ~/.gitconfig files will also be parsed for diff coloring.  git diff color slots (`"color.diff.SLOT"`) supported are `"new"`, `"old"`, `"meta"`, `"frag"`, `"func"`, and `"context"`.

## OPTIONS

Most [**git-config**(1)](/git-config/1.md) command-line switches are accepted by `"lei config"` as is.  The most frequently used options are expected to be:

- \-e

  - \--edit

  Open an editor to edit the lei config file.

- \-l

  - \--list

  List all variables set in config file, along with their values.

## 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\>
