Skip to content

Support for key, value pairs without a section? #44

Description

@kvrohit

As described in this wiki article: https://en.wikipedia.org/wiki/INI_file#Sections

Keys may, but need not, be grouped into arbitrarily named sections

I want to create an ini file that resembles something like this:

authorityKeyIdentifier=keyid,issuer
basicConstraints=CA:FALSE
keyUsage = digitalSignature, nonRepudiation, keyEncipherment, dataEncipherment
subjectAltName = @alt_names

[alt_names]
DNS.1 = *.github.com

Notice that the first set of key, value pairs do not belong to any section.

Using tini for creating this type of ini results in the following:

[]
authorityKeyIdentifier = keyid,issuer
basicConstraints = CA:FALSE
keyUsage = digitalSignature, nonRepudiation, keyEncipherment, dataEncipherment
subjectAltName = @alt_names

[alt_names]
DNS.1 = *.github.com

Is there a way to tell it to not create the empty [] section?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions