Subject: hjson file format

From: Hadmut Danisch <[email-masked]>
Date: Wed, 13 Mar 2024 00:53:00 +0200

Hi,

just a question and proposal:

I was preparing to try nncp on several machines, but found, that the 
hjson file format for /etc/nncp.hjson cannot easily distributed with 
automatic installation tools like ansible or puppet, because

  * it contains both public and secret data, and thus cannot be
    distributed as one file without modification,

  * it cannot be generated (easily) on the machine with common tools (to
    compose public and secret data into a single file), since it is not
    compatible to json and virtually no tool supports hjson.

I therefore would like to make two proposals:

 1. Either split the secrect parts (the self-key) and the public parts
    (shared with others) into two distinct files, to allow easy
    distribution and update of nncp.hjson or

 2. alternatively allow use of either YAML file format, because YAML is
    designed to be easy human-readible and easy human-editable, but in
    contrast to hjson widely used and very well supported by a huge
    number of tools and programming library. In my eyes, YAML would be a
    better choice, since it also fulfills nncp's requirements, but it is
    even easier to read and edit ( no braces needed), and there's lot of
    tools to compose.

    And, YAML is a common standard for configuration files.

    If not YAML, then regular JSON, because there's tools for it (like jq).

with best regards

Hadmut