DevFlow CLI — Commands, Flags and Examples
Every flag the CLI accepts, what it does and an example you can paste. The list below matches the implementation in the repository — no flag is documented here that does not exist.
Synopsis
devflow [options]
create-devflow [options]
npx create-devflow [options]Install and run
No installation is required — npx fetches the latest published version. To pin a version in a project, add it as a development dependency.
Requirements: Node.js 18, 20 or 22, and a project with a package.json. The installation guide has the details.
All flags
| Flag | Description | Example |
|---|---|---|
| --dry-run | Prints the execution plan and writes nothing to disk. | npx create-devflow --dry-run |
| --all | Applies the recommended preset for the detected stack, without opening the wizard. | npx create-devflow --all |
| --only <module> | Applies a single module by id. Unknown ids exit with an error and print the valid list. | npx create-devflow --only vitest |
| -y, --yes | Skips the confirmation prompt. | npx create-devflow --all --yes |
| --skip-install | Generates the files and scripts but does not install the packages. | npx create-devflow --only eslint --skip-install |
| --pm <manager> | Forces the package manager: npm, pnpm, yarn or bun. Overrides the detected value. | npx create-devflow --pm pnpm |
| --ci <provider> | Selects the CI provider: github, gitlab or both. Generates the matching workflow. | npx create-devflow --ci github |
| --scope <pattern> | Workspace glob pattern used when generating monorepo configuration. | npx create-devflow --only workspaces --scope "packages/*" |
| --verbose | Prints debug output, including skipped files. | npx create-devflow --dry-run --verbose |
| -h, --help | Prints the help message. | — |
| -V, --version | Prints the installed version. | — |
Module shortcuts
These flags skip the wizard and expand to the modules they own. They can be combined with each other and with the flags above.
| Flag | Applies |
|---|---|
| --husky | husky, lint-staged, commitlint |
| --lint | eslint, prettier, editorconfig |
| --test | vitest |
| --docker | dockerfile, docker-compose, dockerignore |
| --docs | readme, contributing, code-of-conduct, security-md, license |
| --security | audit, gitleaks |
| --release <tool> | release-it, changesets or semantic-release |
Examples
Preview everything before it happens
Prints the files to create, the packages to install and the scripts to add, then exits. Nothing is written and no package is installed.
Set up the recommended workflow
Applies the recommended preset for the detected stack. The flag combination also skips the confirmation prompt, which is what you want in a bootstrap script.
Add only GitHub Actions
Generates .github/workflows/ci.yml and nothing else. The workflow calls the lint, typecheck, test and build scripts, so those modules have to exist in your project.
Add linting and Git hooks
ESLint, Prettier and EditorConfig, plus Husky, lint-staged and Commitlint. This is the combination most React and TypeScript projects want.
Force pnpm and GitHub Actions
Generates a GitHub Actions workflow that installs with pnpm and caches the pnpm store, even if the lock file is missing.
Generate files without installing anything
Writes eslint.config.mjs and adds the lint scripts, but leaves the dependency installation to you. The summary lists the packages you still need.
Every module id
The --only flag accepts any of these ids. The module pages list the exact files, packages and scripts each one produces.
Example: npx create-devflow --only vitest
Compatibility matrix
What each stack gets, and which package managers and CI providers are supported. The matrix reflects the module implementations, not an aspiration.
| Stack | ESLint plugins | Vitest env | Testing Library |
|---|---|---|---|
| Next.js | typescript-eslint, react, react-hooks | jsdom | @testing-library/react |
| React | typescript-eslint, react, react-hooks | jsdom | @testing-library/react |
| Nuxt | typescript-eslint, vue | jsdom | @testing-library/vue |
| Vue | typescript-eslint, vue | jsdom | @testing-library/vue |
| NestJS | typescript-eslint | node (not in the recommended preset) | — |
| Node.js | typescript-eslint | node | — |
| SvelteKit | typescript-eslint | node | — |
Package managers
- npm — supported. `npm ci`, `npm run`, `npm audit --audit-level=high`.
- pnpm — supported. Corepack, `pnpm install --frozen-lockfile`, `pnpm run`.
- yarn — supported. Corepack, `yarn install --frozen-lockfile`, `yarn run`.
- bun — supported. `bun install --frozen-lockfile`, `bun run`. No dependency cache in the generated workflow, because Bun is installed by its own action.
CI providers
- GitHub Actions — supported. Generated as `.github/workflows/ci.yml`.
- GitLab CI — supported. Generated as `.gitlab-ci.yml`.
- Both — supported. `--ci both` writes the two workflow files.
- Other providers — not generated. The workflow is a plain YAML file, so it can be translated by hand.
Exit codes
| Code | Meaning |
|---|---|
| 0 | The plan was applied successfully. |
| 1 | An unknown module id, an unknown release tool or an unknown CI provider was passed. |
FAQ
Does DevFlow overwrite my existing ESLint config?
No. Every configuration file is created with skip-if-exists semantics, so an existing eslint.config.mjs, .prettierrc.json, .husky/pre-commit or any other generated file is left untouched. DevFlow does rewrite package.json, but it only merges: existing scripts are never replaced, and new scripts are added alongside them.
Does create-devflow support pnpm, yarn and bun?
Yes. The package manager is detected from the lock file (pnpm-lock.yaml, yarn.lock, bun.lockb or package-lock.json) or the packageManager field, and the install command, CI workflow and Dockerfile are all generated for the detected manager. Use --pm pnpm, --pm yarn or --pm bun to override detection.
Can I add only GitHub Actions without Docker?
Yes. Run npx create-devflow --ci github to generate only .github/workflows/ci.yml, or use --only <module> to select any single module. Every module can be applied on its own.
How do I remove DevFlow from my repository?
DevFlow has no --undo flag, but everything it writes is plain text in your repository. Delete the generated files listed on each module page, remove the scripts it added from package.json, and remove the devDependencies it installed. Running the tool in a clean git checkout and reviewing the diff is the safest way to see exactly what changed.
Does DevFlow support Next.js App Router?
Yes. A project with the next dependency is detected as a Next.js stack, which means DevFlow generates the React + TypeScript ESLint flat config and the React Testing Library setup. The same config works for both the App Router and the Pages Router, because DevFlow does not add framework-specific Next.js ESLint plugins that would be tied to a router.
Does DevFlow work with Nx and Turborepo?
Yes. The monorepo category contains Nx, Turborepo and workspace modules, and a project with nx.json or turbo.json is detected as a monorepo. DevFlow generates the nx.json or turbo.json configuration and the turbo scripts. The generated CI workflow is a single-repository pipeline, so monorepo caching and affected-only runs are covered in the Turborepo CI guide.
How do I run DevFlow in dry-run mode?
Add --dry-run to any command, for example npx create-devflow --dry-run for the wizard or npx create-devflow --all --dry-run for the recommended preset. DevFlow then prints the execution plan — files to create, packages to install and scripts to add — and writes nothing to disk.
Is DevFlow free and open source?
Yes. DevFlow is MIT licensed, published on npm as create-devflow, and the full source is available on GitHub. There is no paid tier, no telemetry and no account required.
What Node.js versions does DevFlow support?
Node.js 18, 20 and 22. The package declares node >=18.0.0 in its engines field, and the generated CI workflow runs on Node.js 20 by default.
Does DevFlow work on Windows?
DevFlow runs on macOS, Linux and Windows through WSL2. It is a Node.js CLI with no native binary dependencies, and the generated files use POSIX-style paths and LF line endings.
What is the difference between --all and the interactive wizard?
--all applies the recommended preset for the detected stack without asking any questions. The wizard lets you pick modules one by one, tune settings such as commit strictness and CI provider, and review the execution plan before it is applied. Both paths use the same module implementations.
Can I combine several flags at once?
Yes. Flags can be combined, for example npx create-devflow --lint --test --ci github. Each flag expands to the modules it owns and the union of all selected modules is applied in one plan.
Does --only accept more than one module?
No, --only takes exactly one module id and exits with an error if the id is unknown, printing the list of valid ids. To select several modules, use the dedicated flags or the interactive wizard.
See also
- Dry run mode — what the preview output means
- Presets — what
--allapplies - Configuration — how the stack and package manager are detected
- Module catalogue — what every module generates