create-nestjs-inspire-template
v1.0.0
Published
Scaffold a new NestJS backend from the Inspire template (Prisma, domain-oriented structure, crypto)
Maintainers
Readme
create-nestjs-inspire-template
This folder is the source for the npm package that lets users run:
npx create-nestjs-inspire-template my-appIt is published as a separate npm package from a separate Git repository. The template that users get is the parent repo (nestjs-inspire-template), which must be pushed to GitHub first.
Before first publish
- Set the template repo in
index.js: editTEMPLATE_REPOto your GitHubowner/repo(e.g.your-org/nestjs-inspire-template). - Push the template: From the parent repo root, push the template to GitHub so it is public (e.g.
github.com/your-org/nestjs-inspire-template).
How to publish this package
- Create a new repository on GitHub (e.g.
your-org/create-nestjs-inspire-template). - Copy only the contents of this folder (
create-package/) into that new repo (e.g.package.json,index.js, this README). Do not copy the rest of the NestJS template. - In the new repo:
npm install npm version 1.0.0 # if needed npm publish - To update the template that users get, push changes to the template repo (nestjs-inspire-template). The create script always clones the latest default branch.
- To change the installer (e.g. fix bugs, change prompts), edit this package, then in the create-package repo: bump version,
npm publish.
Local test (without publishing)
From this directory:
npm install
node index.js ../test-my-appUse a path outside the template repo (e.g. /tmp/test-my-app) so degit can clone the template from GitHub. Ensure the template repo is already pushed and public.
