[Nut-upsdev] NUT Augeas Lens definitions - help wanted

Jim Klimov jimklimov at gmail.com
Mon Apr 29 11:25:51 BST 2024


Cheers all,

  With PR https://github.com/networkupstools/nut/pull/2425 I've paid some
attention to the tools we have to help external consumers edit NUT
configuration files. These go back to issues like
https://github.com/networkupstools/nut/issue/2294 (originally posted for
"nutconf" improvement, and now with some more TODO's linked to it) and
https://github.com/networkupstools/nut/issue/657 about known unfinished
business with augeas as of quite a while ago.

  My investigation with the latter found that the parser seems to work for
simple wordings, which frankly covers the majority of use-cases, but fails
for some cases that are valid for NUT - such as multi-word tokens encased
into double quotes, or a number of these on a line, or even including an
escaped double-quote as content, at least this is a whole bunch of
problematic cases that I stumbled upon.

  If there are people well-versed in augeas definitions (or willing to
learn), some PRs to improve the existing ones would be welcome :)

  Issue 657 suggested picking up rules from shell-oriented lens
definitions. That sounds like a decent route to try.

Thanks in advance,
Jim Klimov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/nut-upsdev/attachments/20240429/cf303aee/attachment.htm>


More information about the Nut-upsdev mailing list