Hi all,

The virtual alias table format of Postfix gives special meaning to
leading whitespace under certain conditions:

```
multi-line text
     A  logical  line  starts  with  non-whitespace text. A line that
     starts with whitespace continues a logical line.
```

http://www.postfix.org/virtual.5.html

I have lots of entries in those files following this example.
Especially the prefix `a` is of different lengths for multiple
different lines.

```
# Some comment...
d...@example.org           recipient
c...@example.org         recipient
b....@example.org       recipient
a.b....@example.org     recipient
aa.b....@example.org    recipient
aaa.b....@example.org   recipient
```

To make things better readable, I would like to have the following
layout of the same entries instead: 

```
# Some comment...
        d...@example.org recipient
      c...@example.org recipient
    b....@example.org recipient
  a.b....@example.org recipient
 aa.b....@example.org recipient
aaa.b....@example.org recipient
```

Or sometimes the same approach with a different order. Though, the
former example would be more common in theory. 

```
# Some comment...
aaa.b....@example.org recipient
 aa.b....@example.org recipient
  a.b....@example.org recipient
    b....@example.org recipient
      c...@example.org recipient
        d...@example.org recipient
```

So, the difference really only is to add leading whitespace to make
things more readable. The current implementation would warn about and
ignore entries in the first example and in the second use all as
continuation of the first entry. Reason for the first case seems to be
an arbitrary decision about how "readllines" is implemented:

> Invalid input: continuing text without preceding text. Allowing this
> would complicate "postconf -e", which implements its own multi-line
> parsing routine. Do not abort, just warn, so that critical programs
> like postmap do not leave behind a truncated table.

https://repositories.muehmer.net/boris.muehmer/postfix/-/blob/c8a78361ae41ffc8a4cf4f3e4ca2b1bca306b8ba/src/util/readlline.c#L122

It would be great if this decision could be reconsidered, e.g. by
using a config influencing the behavior or alike. For example, I don't
use continuation at all in my config files and would happily disable
that "parsing mode" in favour of better readable entries. would be
great to have a choice.

Thanks!

Mit freundlichen Grüßen

Thorsten Schöning

-- 
AM-SoFT IT-Service - Bitstore Hameln GmbH
Mitglied der Bitstore Gruppe - Ihr Full-Service-Dienstleister für IT und TK

E-Mail: thorsten.schoen...@am-soft.de
Web:    http://www.AM-SoFT.de/

Tel:   05151-  9468- 0
Tel:   05151-  9468-55
Fax:   05151-  9468-88
Mobil:  0178-8 9468-04

AM-SoFT IT-Service - Bitstore Hameln GmbH, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 221853 - Geschäftsführer: Janine Galonska


Für Rückfragen stehe ich Ihnen sehr gerne zur Verfügung.

Mit freundlichen Grüßen

Thorsten Schöning


Tel: 05151 9468 0
Fax: 05151 9468 88
Mobil: 
Webseite: https://www.am-soft.de 

AM-Soft IT-Service - Bitstore Hameln GmbH i.G. ist ein Mitglied der Bitstore 
Gruppe - Ihr Full-Service-Dienstleister für IT und TK

AM-Soft IT-Service - Bitstore Hameln GmbH i.G.
Brandenburger Str. 7c
31789 Hameln
Tel: 05151 9468 0

Bitstore IT-Consulting GmbH
Zentrale - Berlin Lichtenberg
Frankfurter Allee 285
10317 Berlin
Tel: 030 453 087 80

CBS IT-Service - Bitstore Kaulsdorf UG
Tel: 030 453 087 880 1

Büro Dallgow-Döberitz
Tel: 03322 507 020

Büro Kloster Lehnin
Tel: 033207 566 530

PCE IT-Service - Bitstore Darmstadt UG
Darmstadt
Tel: 06151 392 973 0

Büro Neuruppin
Tel: 033932 606 090

ACI EDV Systemhaus - Bitstore Dresden GmbH
Dresden
Tel: 0351 254 410

Das Systemhaus - Bitstore Magdeburg GmbH
Magdeburg
Tel: 0391 636 651 0

Allerdata.IT - Bitstore Wittenberg GmbH
Wittenberg
Tel: 03491 876 735 7

Büro Liebenwalde
Tel: 033054 810 00

HSA - das Büro - Bitstore Altenburg UG
Altenburg
Tel: 0344 784 390 97

Bitstore IT – Consulting GmbH
NL Piesteritz 
Piesteritz
Tel: 03491 644 868 6

Solltec IT-Services - Bitstore Braunschweig UG
Braunschweig
Tel: 0531 206 068 0

MF Computer Service - Bitstore Gütersloh GmbH
Gütersloh
Tel: 05245 920 809 3

Firmensitz: AM-Soft IT-Service - Bitstore Hameln GmbH i.G. , Brandenburger Str. 
7c , 31789 Hameln
Geschäftsführer Janine Galonska






Reply via email to