-
Notifications
You must be signed in to change notification settings - Fork 280
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feat] Render to INI-style formats #137
Comments
It's a totally legit ask. For other output formats, especially "simpler" ones, we recommend implementing them in Pkl itself. We did this with the TOML renderer, for example: https://github.com/apple/pkl-pantry/tree/main/packages/pkl.toml Since bandwidth is indeed limited, you might want to have a go at it that way yourself; we're more than happy to support / review / etc. and since this can be written in Pkl itself, it doesn't require expertise about Pkl internals. |
Hi, ill have a look at starting to create a |
I love that |
Its looking good so far the int = 123
float = 1.23
bool = true
string = Pigeon
unicodeString = abc😀abc😎abc
multiLineString = have a
great
day
[map]
one = 123
two = 1.23
three = true
four = Pigeon
five = abc😀abc😎abc
six = have a
great
day
[map.seven]
name = Pigeon
[mapping]
one = 123
two = 1.23
three = true
four = Pigeon
five = abc😀abc😎abc
six = have a
great
day
[mapping.seven]
name = Pigeon
[typedObject]
name = Pigeon
age = 30
[typedObject.address]
street = Folsom St.
[container]
name = Pigeon
age = 30
[container.address]
street = Folsom St. |
Its now outputting correctly and handles escape chars. Is there anywhere else i need to add the |
Nice! Do you want to PR this? That will make it a little easier to iterate. To add a new in-language renderer, you will need to create a new standard library module. To do that:
You will also need to add language snippet tests for this renderer, in pkl-core/src/test/files/LanguageSnippetTests/input/api/ |
Also make sure that you follow the contribution guidelines |
Created PR. Ill create the new in-language renderer soon and open another PR. Thank you for the help. |
I know your bandwidth is limited, just putting it out there. I would love to see support for INI-like formats, such as systemd configuration files or even just plain ini files.
Here are the INI-style formats I can think of:
Feel free to suggest more and I'll add them to the list
The text was updated successfully, but these errors were encountered: