Commit Graph

19 Commits

Author SHA1 Message Date
Robin Jarry ebcd6fcea1 lint: check for bad white space habits
A little coding hygiene cannot hurt. Add a simple awk script to check
all source files for bad white space habits:

- trailing white space
- trailing new lines at the end of files
- missing new line at the end of files
- spaces followed by tabs

The script outputs color when the terminal supports it. It exits with
a non-zero code when there was at least one white space issue found.
Call the script in the lint step.

Example output of the awk script:

 config/default_styleset:1:# <-- trailing whitespace
 config/default_styleset:3:# <-- trailing whitespace
 doc/aerc.1.scd:78:        Executes an arbitrary command in the background. Aerc will set the <-- trailing whitespace
 doc/aerc.1.scd:234:        <-- trailing whitespace
 doc/aerc.1.scd:237:        <-- trailing whitespace
 worker/types/thread_test.go:74:        //         return ErrSkipThread<-- space(s) followed by tab(s)
 worker/lib/testdata/message/invalid/hexa: trailing new line(s)

Fix issues reported by the script.

NB: The ENDFILE match is a GNU extension. It will be ignored on BSD-awk
and trailing new lines will not be detected. The lint make target is
only invoked on alpine linux which has GNU awk anyway.

NB: Empty cells in scdoc tables require trailing white space... Avoid
this by setting content in these cells. I don't really see a use for
empty cells.

Signed-off-by: Robin Jarry <robin@jarry.cc>
Tested-by: Moritz Poldrack <moritz@poldrack.dev>
2022-10-19 10:19:19 +02:00
Thomas Faughnan 62ac7a5071 doc: fix man page typos
"behaviour" is not necessarily a typo, but currently 3/4 instances of
the word in the docs use the spelling "behavior".

Signed-off-by: Thomas Faughnan <tom@tjf.sh>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-08-22 09:49:26 +02:00
Joel Pickett e73e5065b0 doc: fix blink config example
Signed-off-by: Joel Pickett <mail@vyryls.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-07-30 17:58:27 +02:00
Robin Jarry 011d41de7e doc: fix typos
These were reported by lintian when packaging aerc 0.11.0. There are
probably others.

Signed-off-by: Robin Jarry <robin@jarry.cc>
Acked-by: Moritz Poldrack <moritz@poldrack.dev>
2022-07-18 13:58:27 +02:00
Tim Culverhouse afe35839ed style: add style config options for dirlist_unread and dirlist_recent
Adds two style options: dirlist_unread and dirlist_recent. These options
apply in layers, in the same way as msglist_* styles do.

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-04-27 09:46:06 +02:00
Tobias Wölfel e810ae12d7 stylesets: allow specifying color by number
Make it possible to specify the color in the style sets by number in
addition to the color name. This allows using colors defined by the
terminal.

Signed-off-by: Tobias Wölfel <tobias.woelfel@mailbox.org>
Acked-by: Robin Jarry <robin@jarry.cc>
2022-04-07 12:51:09 +02:00
Ariel Costas 7c945149a6 doc: correct typo in man-pages
Fix a typo in the man page where it reads "maintained by by Robin"
instead of "maintained by Robin"

Signed-off-by: Ariel Costas <ariel@costas.dev>
2022-01-26 19:23:29 +01:00
Dian M Fay f776fb8246 style: customize vertical and horizontal border characters
New border-char-horizontal and border-char-vertical config settings in
aerc.conf allow users to modify border appearance from the default
1-wide/tall blank space. In stylesets, border.fg now affects the
foreground color when custom characters are defined.

Signed-off-by: Robin Jarry <robin@jarry.cc>
2021-11-30 15:05:33 +01:00
Robin Jarry 44ad5f9a25 doc: update authors
Signed-off-by: Robin Jarry <robin@jarry.cc>
2021-11-09 20:11:42 +01:00
Chris Vittal f9bba3d17d Apply relevant msglist styles in order
Allow styles to be layered over a base style. The list of styles to
apply is layered over the base style in order, such that if the layer
does not differ from the base it is not used. The order that these
styles are applied in is, from first to last:

msglist_default
msglist_unread
msglist_read    (exclusive with unread, so technically the same level)
msglist_flagged
msglist_deleted
msglist_marked

So, msglist_marked style dominates.

This fixes an issue where the msglist_deleted style was not being applied.
2020-11-01 09:50:58 +01:00
Thorben Günther 9f89fe1108 aerc-stylesets: properly indent examples 2020-08-07 18:10:48 +02:00
Kalyan Sriram 1023dd9588 Rename selecter to selector 2020-08-06 21:42:06 +02:00
Kalyan Sriram 905cb9dfd3 Implement style configuration.
Introduce the ability to configure stylesets, allowing customization of
aerc's look (color scheme, font weight, etc). Default styleset is
installed to /path/to/aerc/stylesets/default.
2020-08-06 21:42:06 +02:00
Reto Brunner 3d784c5d8c Revert "Implement style configuration."
This reverts commit 1ff687ca2b.
2020-07-30 23:22:32 +02:00
Reto Brunner 6ee7b1c3fd Revert "Rename selecter to selector"
This reverts commit 2c244222d5.
2020-07-30 23:22:16 +02:00
Kalyan Sriram 2c244222d5 Rename selecter to selector 2020-07-30 19:35:59 +02:00
Kalyan Sriram 1ff687ca2b Implement style configuration.
Introduce the ability to configure stylesets, allowing customization of
aerc's look (color scheme, font weight, etc). Default styleset is
installed to /path/to/aerc/stylesets/default.
2020-07-30 19:35:59 +02:00
Drew DeVault caad1b2c06 Revert "Add Style configuration"
This reverts commit 0f78f06610.
2020-05-28 10:32:42 -04:00
Reto Brunner 0f78f06610 Add Style configuration
The following functionalities are added to configure aerc ui styles.
- Read stylesets from file with very basic fnmatch wildcard matching
- Add default styleset
- Support different stylesets as part of UiConfig allowing contextual
  styles.
- Move widgets/ui elements to use the stylesets.
- Add configuration manual for the styleset
2020-05-27 07:57:10 +02:00