Base
Scaffold a base monorepo project with workspaces configuration, ready for adding framework workspaces. This command is optional: use it when you want the project root now but do not want to choose an app or documentation framework yet.
| What you want now | Command to start with | Result |
|---|---|---|
| Only an empty Nova monorepo root | nova scaffold starter base | Root, apps/, and packages/ |
| A root and the first app together | nova scaffold app <framework> | Root plus the app workspace |
| A root and documentation together | nova scaffold docs docusaurus | Root plus the docs workspace |
| A root and a package together | nova scaffold package <type> | Root plus the package workspace |
You do not need to run starter base before a direct app, docs, or package command.
Why Use This Command?
- Creates the root
package.jsonwithworkspacesconfigured forapps/*andpackages/*so you can add workspaces immediately. - Creates standard
dev,prod,check,build,deploy, andcleanscripts. Each one runsnova utility run-workspaces, which runs the root's ownname:*steps first and then every workspace'snamescript in dependency order. - Pins the npm and Node.js toolchain used by current Nova projects and records explicit install-script decisions used by the built-in scaffolds.
- Generates a baseline
nova.config.jsonwith the project name, current starting year,nodejsproject platform, andExample Companylegal-name placeholder so recipes, utilities, and identity-aware workspaces have valid input from the start. - Registers the root environment namespace and generates
.envplus.env.samplewith Nova's Node.js and logging defaults. - Generates Nova's canonical root
.gitignorefor secrets, dependencies, build output, editor metadata, and supported platform tooling. - Installs
@cbnventures/novaas a dependency so its CLI, presets, and runtime toolkit remain available to generated workspaces. - Adds root Vitest coverage for dotenv formatting and the private monorepo coordinator contract, backed by Nova's shared test setup.
Requirements
- Node.js runtime — Use any Node.js LTS release.
- Start outside a project — Run the command where Nova cannot find a
package.json. The selected output may already contain unrelated files, but Nova refuses to replacepackage.jsonornova.config.json.
Usage
Options
| Flag | Description |
|---|---|
-d, --dry-run | Run without writing any files. |
--install | Install dependencies after scaffolding; this is the default. |
--no-install | Skip dependency installation. |
--name <name> | Project name. |
--non-interactive | Require every answer as a flag and do not open prompts. |
--output <dir> | Output directory. |
Output Structure
{project-slug}/
├── apps/
├── packages/
├── tests/
│ ├── dotenv.test.ts
│ ├── project.test.ts
│ └── setup.ts
├── .env
├── .env.sample
├── .gitignore
├── eslint.config.mts
├── nova.config.json
├── package.json
├── tsconfig.config.json
├── tsconfig.tests.json
└── vitest.config.mts
How It Works
Interactive Wizard
When run without flags, the command collects the project details before writing anything:
- Project name — Enter a slug for your monorepo (e.g.
my-app).
Nova creates the project in ./{project-name} by default, displays the complete plan, and asks for one confirmation. A new project never writes directly into the current directory. Dependencies install after the files are ready unless you pass --no-install. Project-level generators remain separate commands that you can run after configuring nova.config.json.
Non-Interactive Mode
Agents and automation should add --non-interactive and provide --name. --output is optional and defaults to ./{project-name}. Nova validates the complete plan before writing and installs dependencies unless the command includes --no-install.
Safety Checks
Before creating any file, Nova validates the project slug and checks every root path it owns, including .gitignore, package.json, and nova.config.json. If any target file already exists, the command stops and lists the conflict. --dry-run performs the same validation and reports the exact root path without writing.
Next Steps
After scaffolding, enter the new monorepo and add as many workspaces as the project needs. Each scaffold command detects the existing workspace root, creates only the requested workspace, adds it to the same nova.config.json, and merges its required runtimes and deployment targets into project.platforms. Running another scaffold command later preserves the workspaces and platforms that are already registered.
For example, these commands add a Docusaurus documentation site and a Cloudflare Workers serverless tool to one project:
You can mix any supported app, docs, package, and tool scaffolds this way. Run each command from the monorepo root, not from inside an existing workspace.
Once the workspaces are in place, run generators for additional project-level files like .editorconfig, LICENSE, and README.md. The root .gitignore is already generated by the scaffold.