Skip to content
Adebayo Obikoya
Back to projects

Open source · 2025

PNest CLI

A command-line wrapper around the NestJS CLI that starts projects from fuller templates.

Role
Author
Version
0.1.0
Stack
TypeScript, Node.js, Commander
Status
Early prototype; not on npm yet

Why it exists

nest new gives you a minimal starter, so the same setup (validation, Swagger, an API prefix, a response format, Docker) gets redone by hand for every new service. PNest keeps that setup in templates and puts the usual Nest commands behind the same pnest command.

What it does

  • pnest new, build, start and generate forwarded to the Nest CLI with the same arguments
  • A rest-api template with an API prefix, validation, Swagger and a standard response shape
  • Options for Docker files, skipping install and skipping git
  • A plugin system, starting with a logger plugin (Winston or Pino)

Decisions that mattered

  1. 01

    Forward, don’t reimplement

    PNest passes Nest commands through unchanged, using the project’s own Nest CLI when there is one, so it never drifts from what Nest itself does.

  2. 02

    Templates over generators

    A template is a real project you can read and run, which makes it easier to keep current than code that writes code.

Where it is now

Version 0.1.0. Nest commands and templates work; plugins are recorded but can’t install until they’re published to npm.

Next projectCliqpay