Scaffold get‑dotenv config files and a host‑based CLI skeleton with safe collision flow and CI heuristics.
// Recommended: plugins barrel (shares type identity with cliHost)
import { initPlugin } from '@karmaniverous/get-dotenv/plugins';
Per‑plugin subpaths remain available when needed:
import { initPlugin } from '@karmaniverous/get-dotenv/plugins/init';
getdotenv init [dest] [options]
Options:
--config-format <json|yaml|js|ts> Config format (default: json)--with-local Include the .local variant (JSON/YAML)--dynamic Include dynamic examples (JS/TS configs)--cli-name <string> CLI name for skeleton and token replacement--force Overwrite all existing files--yes Skip all collisions (no overwrite)[o/e/s] and “all” variants [O/E/S].--yes unless --force.--force > --yes > auto‑detect..gitignore to include getdotenv.config.local.* and *.local.JSON + local + CLI named “acme”:
getdotenv init . \
--config-format json \
--with-local \
--cli-name acme \
--force
TypeScript config + CLI named “toolbox”:
getdotenv init ./apps/toolbox \
--config-format ts \
--cli-name toolbox
getdotenv.config.* (public; and .local if requested)src/cli/<name>/index.ts and src/cli/<name>/plugins/hello/ skeleton (index, options, actions, types)import { createCli } from '@karmaniverous/get-dotenv/cli';
import { batchPlugin } from '@karmaniverous/get-dotenv/plugins/batch';
import { awsPlugin } from '@karmaniverous/get-dotenv/plugins/aws';
const run = createCli({
alias: 'acme',
compose: (p) =>
p
.use(batchPlugin())
.use(awsPlugin()),
});
await run();