From 79a051051e27621a6b9098559295b0b73944ec60 Mon Sep 17 00:00:00 2001 From: Marjukka Niinioja Date: Mon, 6 Jul 2026 21:11:21 +0300 Subject: [PATCH 01/12] improve create-apiops package and cli --- README.md | 32 ++++- packages/create-apiops/README.md | 62 +++++++++ .../bin/create-apiops-project.js | 128 +++++++++++++++--- scripts/test-create-apiops-scaffold.mjs | 101 ++++++++++++-- 4 files changed, 296 insertions(+), 27 deletions(-) create mode 100644 packages/create-apiops/README.md diff --git a/README.md b/README.md index 6e9ebca..b8f826e 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,40 @@ ## Create a new APIOps project (CLI) +Interactive scaffold: + ```bash npm create apiops@latest ``` -This command runs the `create-apiops` initializer package and generates a starter APIOps project template in your current directory. This is useful for a scaffolded proces (with or without AI) to create or review requirements for new APIs or improve existing APIs. +Named project scaffold: + +```bash +npm create apiops@latest report-conversion-apiops +``` + +Non-interactive scaffold: + +```bash +npm create apiops@latest -- --name report-conversion-apiops --locale en --style REST --yes +``` + +When using `npm create`, pass initializer flags after the `--` separator. Flags before the separator are handled by npm itself and may not reach `create-apiops`. + +To inspect the initializer options without starting prompts: + +```bash +npm create apiops@latest -- --help +``` + +Useful options: + +- `--name ` or the first positional argument sets the project directory and package name +- `--locale ` sets the default method locale, such as `en` or `fi` +- `--style