Hello, On 2024/09/01 12:44:47 +0200, Philipp <[email protected]> wrote: > Hi all > > I had a bit time to improve the format speciers of the filters. The > filters now support '%u' for the key and '%h' for the table name. This > speciers are choosen to be compatible with login_ldap(8) of openbsd[0].
sounds like a great idea, thank you! :) > The '%s' specifier still works as the key for backwords compability. > > I also have written a manpage. I hope it is understandable and the troff > is correct. > > Patches are attached. > > Philipp > > [0] I plan to send my version of aldap to openbsd, so openbsd also > benefit from my improvements. But I haven't had the time to do so. some nits on the manpage. no need to send an updated diff, i'll commit the fixes on top. I'll commit tomorrow, just after giving another read at the code changes :) > --- /dev/null > +++ b/table-ldap.5 > [...] > +.Pp > +A LDAP table consists of a LDAP tree starting from a base. > +Each table lookup will search for the matching objects. > + No empty lines please. Use +.Pp instead. > +.Sh LDAP TABLE CONFIG FILE > +.Ss COMMON OPTIONS > [..] > +.Sh FORMAT SPECIFIERS > + > +The filter options are designed to allow per request > +Filters allow some specifiers in the attribute values of the filter. > +The following speciers are defined: > + > +.Bl -column %s -offset indent please don't use the table format is possible. It would render almost the same if written Bl -tag -width Ds -compact It %u The key of the request It %h [...] Ed and is more idiomatic. > +.It %u The key of the request > +.It %h The name of the table > +.It %% The literal '%' > +.It %s Depricated alias for the the key > +.El P.S.: I find very useful to run the manpages through mandoc -Tlint (even just man -T lint if man(1) is mandoc(1) such as on OpenBSD) to spot these kind of issues. Cheers, Omar Polo
