pkl icon indicating copy to clipboard operation
pkl copied to clipboard

[feat] Render to dotenv-style formats

Open linux-china opened this issue 2 years ago • 3 comments

.env accepted by lots of frameworks, and easy to be converted to environment variables.

For example, pkl as following:

name="joe"
server {
   host = "localhost"
  port =8080
}

and the pkl could be rendered to dotenv-style:

NAME="joe"
SERVER_HOST="localhost"
SERVER_PORT=8080

linux-china avatar Mar 01 '24 00:03 linux-china

I'll work on this issue

LloydNA avatar Mar 02 '24 02:03 LloydNA

FYI--it's possible to define an in-language renderer; a renderer doesn't need to be part of the standard library.

For an example of an in-language renderer, see pkl.toml

bioball avatar Mar 02 '24 03:03 bioball

@LloydNA Is this currently a WIP?

jtagrgh avatar Mar 18 '24 19:03 jtagrgh