mirror of
https://github.com/HeyPuter/puter.git
synced 2026-05-03 16:10:31 +00:00
11e057557d
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
test / backend (node env, api-test) (22.x) (push) Has been cancelled
test / puterjs (browser env, playwright) (22.x) (push) Has been cancelled
test / puterjs (node env, vitest) (22.x) (push) Has been cancelled
26 lines
632 B
JavaScript
26 lines
632 B
JavaScript
import dedent from 'dedent';
|
|
import configVals from './config-vals.json.js';
|
|
|
|
const mdlib = {};
|
|
mdlib.h = (out, n, str) => {
|
|
out(`${'#'.repeat(n)} ${str}\n\n`);
|
|
};
|
|
|
|
const N_START = 3;
|
|
|
|
const out = str => process.stdout.write(str);
|
|
for ( const configVal of configVals ) {
|
|
mdlib.h(out, N_START, `\`${configVal.key}\``);
|
|
out(`${dedent(configVal.description) }\n\n`);
|
|
|
|
if ( configVal.example_values ) {
|
|
mdlib.h(out, N_START + 1, 'Examples');
|
|
for ( const example of configVal.example_values ) {
|
|
out(`- \`"${configVal.key}": ${JSON.stringify(example)}\`\n`);
|
|
}
|
|
}
|
|
|
|
out('\n');
|
|
|
|
}
|