1
0
mirror of https://github.com/nix-community/home-manager synced 2024-07-03 03:48:31 +02:00
Commit Graph

5 Commits

Author SHA1 Message Date
Genevieve
bec87d536c
aerc: add assertion to limit per-account extraConfig to UI config (#4196)
* aerc: fix per-account extraConfig section names

The aerc configuration file `aerc.conf` can contain 10 different
sections, but only the UI section supports what the aerc manual calls
contextual configuration. This works by appending to the section heading
either `:account=name` or `:folder=bar`.

The aerc-accounts module, however, applied `mkAccountConfig` to each
section heading declared in
`config.accounts.email.accounts.<name>.aerc.extraConfig.*`. This means
home-manager will generate files with `[general:account=default]` and
the options will not be recognized by aerc.

To address this, and since it doesn't make sense for other sections to
only be under a single account's scope, an assertion has been added
to confirm that only sectons that support contextual config (i.e.,
only the UI section) is declared.

This also addresses confusions like declaring
`accounts.email.accounts.*.aerc.extraConfig.general.unsafe-accounts-conf
= true` and triggering a warning message because
`programs.aerc.extraConfig.general.unsafe-accounts-conf` was unset.

This commit also updated documentation throughout the aerc modules to
be in line with this change, and fixed minor typos/formatting therein.

Co-authored-by: Genevieve <genevieve@sunlashed.garden>

* aerc: make assertion plaintext and add test case

This commit adds a test case to check both the warning on unset
`unsafe-accounts-conf = true` when aerc accounts are configured
with Nix, and the new assertion when per-account configuration
contains unsupported subsections (i.e. general).

It also fixes minor formatting issues and typos.
2023-07-14 20:34:28 +02:00
Lukas Nagel
8da1135365
aerc: improve module (#3150)
* aerc: add space after definitions

* aerc: only generate files, if options were set

* aerc: improve file permission warning

* aerc: remove redundant access to builtins

* aerc: allow overwriting of derived values

the order of merging the config subsets did not allow the user to specify
outgoing, source and password command values,
if they were previously derived from the SMTP, IMAP, Maildir etc config.

The values from `account.<name>.extraAccounts` now have the highest precedence.
Appropriate tests were added as well.

* aerc: write primary account first
2023-06-13 10:59:42 +02:00
Patrick Widmer
5cd5a1b585
aerc: add oauth params 2023-04-22 17:07:51 +02:00
patwid
305daba44a
aerc: update auth mechanisms (#3714) 2023-02-27 22:32:12 +01:00
Lukas Nagel
324fedcf9f
Add module for aerc (#3070)
This adds support for configuring email accounts, with automatic smtp, imap,
sendmail (msmpt) and maildir (mbsync, offlineimap) setup in aerc,
via `accounts.email`.
2022-08-11 23:08:28 +02:00