create-template-project 0.4.0 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2025- Dieter Oberkofler
3
+ Copyright (c) 2026 Dieter Oberkofler
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -2,16 +2,29 @@
2
2
 
3
3
  [![NPM Version](https://img.shields.io/npm/v/create-template-project.svg)](https://www.npmjs.com/package/create-template-project)
4
4
  [![NPM Downloads](https://img.shields.io/npm/dm/create-template-project.svg)](https://www.npmjs.com/package/create-template-project)
5
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
6
  [![Node.js CI](https://github.com/doberkofler/create-template-project/actions/workflows/node.js.yml/badge.svg)](https://github.com/doberkofler/create-template-project/actions/workflows/node.js.yml)
6
- [![Coverage Status](https://coveralls.io/repos/github/doberkofler/create-template-project/badge.svg?branch=master)](https://coveralls.io/github/doberkofler/create-template-project?branch=master)
7
+ [![Coverage Status](https://coveralls.io/repos/github/doberkofler/create-template-project/badge.svg?branch=main)](https://coveralls.io/github/doberkofler/create-template-project?branch=main)
7
8
 
8
9
  An ultra-modular, type-safe Node.js CLI tool used to scaffold new project templates (CLI, Web-Vanilla, Web-App, Web-Fullstack) with best-practice configurations pre-installed.
9
10
 
10
- ## Features
11
+ ## 🚀 Quick Start
11
12
 
12
- - **Modern Tech Stack:** All templates come with `commitlint`, `husky`, `vitest`, `oxlint`, `prettier`, and `typescript` (strict mode).
13
+ Run directly without installation:
14
+
15
+ ```bash
16
+ npx create-template-project interactive
17
+ # or
18
+ pnpm dlx create-template-project interactive
19
+ ```
20
+
21
+ ## ✨ Features
22
+
23
+ - **Modern Tech Stack:** All templates come with `commitlint`, `husky`, `vitest`, `oxlint`, `oxfmt`, and `typescript` (strict mode).
13
24
  - **Interactive CLI:** Prompts you for project details if CLI arguments are missing, using `@clack/prompts`.
14
- - **Update Mode:** Detects existing projects and offers a safe update path using `git merge-file`.
25
+ - **🔄 Update Mode:** Detects existing projects and offers a safe update path using `git merge-file`.
26
+ - Files in `src/` and all `*.md` files are skipped to protect your application logic and documentation.
27
+ - Ideal for keeping your project's boilerplate (linting, CI, configs) up-to-date.
15
28
  - **No-Build Option:** Supports creating simple projects without a build step (strips Vite).
16
29
  - **GitHub Integration:** Automatically initializes a Git repository and can create a GitHub repository using the `gh` CLI.
17
30
  - **CI Ready:** Generates GitHub Actions workflows for automated testing and linting.
@@ -19,12 +32,16 @@ An ultra-modular, type-safe Node.js CLI tool used to scaffold new project templa
19
32
  ## Installation
20
33
 
21
34
  ```bash
35
+ pnpm add -g create-template-project
36
+ # or
22
37
  npm install -g create-template-project
23
38
  ```
24
39
 
25
- Or run directly using npx:
40
+ Or run directly using pnpm dlx or npx:
26
41
 
27
42
  ```bash
43
+ pnpm dlx create-template-project
44
+ # or
28
45
  npx create-template-project
29
46
  ```
30
47
 
@@ -47,43 +64,70 @@ You can skip the wizard by using the `create` or `update` commands with the appr
47
64
  #### Create a new project
48
65
 
49
66
  ```bash
50
- create-template-project create --template cli --name my-cool-tool --github
67
+ create-template-project create --template cli --name my-cool-tool --path ./my-cool-tool --github
51
68
  ```
52
69
 
53
70
  #### Update an existing project
54
71
 
55
72
  ```bash
56
- create-template-project update --template cli --name existing-project
73
+ create-template-project update --template cli
57
74
  ```
58
75
 
59
76
  #### Global Options:
60
77
 
78
+ - `--debug`: Enable debug output
61
79
  - `-h, --help`: Show help
62
80
  - `-V, --version`: Show version
63
81
 
64
- #### Command Options (create/update):
82
+ #### Command Options (create):
65
83
 
66
84
  - `-t, --template <type>`: Template type (`cli`, `web-vanilla`, `web-app`, `web-fullstack`)
67
85
  - `-n, --name <name>`: Project name
68
- - `--github`: Create GitHub project (requires `gh` CLI authenticated)
86
+ - `--description <description>`: Project description
87
+ - `-k, --keywords <keywords>`: Project keywords (comma separated)
88
+ - `-a, --author <author>`: Author name (defaults to 'git config user.name')
89
+ - `--github-username <username>`: GitHub username (defaults to 'git config github.user')
90
+ - `-p, --package-manager <pm>`: Package manager (`npm`, `pnpm`, `yarn`) (defaults to `pnpm`)
91
+ - `--create-github-repository`: Create GitHub project (requires `gh` CLI authenticated)
92
+ - `--path <path>`: Output directory (mandatory)
93
+ - `--install-dependencies`: Install dependencies after scaffolding
94
+ - `--build`: Run the CI script (lint, build, test) after scaffolding
95
+ - `--no-progress`: Do not show progress indicators
96
+
97
+ #### Command Options (update):
98
+
99
+ - `-t, --template <type>`: Template type (`cli`, `web-vanilla`, `web-app`, `web-fullstack`)
100
+ - `--description <description>`: Project description
101
+ - `-k, --keywords <keywords>`: Project keywords (comma separated)
102
+ - `-a, --author <author>`: Author name (defaults to 'git config user.name')
103
+ - `--github-username <username>`: GitHub username (defaults to 'git config github.user')
104
+ - `-p, --package-manager <pm>`: Package manager (`npm`, `pnpm`, `yarn`) (defaults to `pnpm`)
105
+ - `--create-github-repository`: Create GitHub project (requires `gh` CLI authenticated)
69
106
  - `-d, --directory <path>`: Output directory (defaults to `.`)
70
- - `--overwrite`: Overwrite existing directory by removing it first (create & update)
71
- - `--no-build`: Create a project without a build step (not allowed for `web-app`)
72
- - `--no-progress`: Do not show progress indicators (useful for AI environments)
107
+ - `--install-dependencies`: Install dependencies after updating
108
+ - `--build`: Run the CI script (lint, build, test) after updating
109
+ - `--dev`: Run the dev server after updating
110
+ - `--open`: Open the browser after updating
111
+ - `--no-progress`: Do not show progress indicators
73
112
 
74
113
  ## Project Templates
75
114
 
76
115
  ### 🟢 CLI
116
+
77
117
  A clean Node.js CLI environment featuring `commander` and `cli-progress`. Supports optional Vite bundling.
78
118
 
79
119
  ### 🔵 Web-Vanilla
120
+
80
121
  Standalone web page setup for modern browsers. Can be used with or without a build step.
81
122
 
82
123
  ### 🟡 Web-App
124
+
83
125
  Modern React application featuring MUI components and TanStack Query for state management.
84
126
 
85
127
  ### ⚛️ Web-Fullstack
128
+
86
129
  A full-stack monorepo featuring:
130
+
87
131
  - **Client**: React with MUI (including Icons) and TypeScript.
88
132
  - **Server**: Express.js backend with tRPC for end-to-end type safety.
89
133
  - **E2E**: Playwright for end-to-end testing.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "dependencies": {
3
3
  "vite": {
4
- "version": "8.0.1",
4
+ "version": "8.0.2",
5
5
  "description": "Native-ESM powered web dev build tool"
6
6
  },
7
7
  "@vitejs/plugin-react": {
@@ -9,11 +9,11 @@
9
9
  "description": "The default Vite plugin for React projects."
10
10
  },
11
11
  "@vitest/browser": {
12
- "version": "4.1.0",
12
+ "version": "4.1.1",
13
13
  "description": "Run Vitest in the browser."
14
14
  },
15
15
  "@vitest/browser-playwright": {
16
- "version": "4.1.0",
16
+ "version": "4.1.1",
17
17
  "description": "Playwright provider for Vitest browser mode."
18
18
  },
19
19
  "playwright": {
@@ -41,7 +41,7 @@
41
41
  "description": "TypeScript definitions for Node.js."
42
42
  },
43
43
  "@vitest/coverage-v8": {
44
- "version": "4.1.0",
44
+ "version": "4.1.1",
45
45
  "description": "V8 coverage provider for Vitest."
46
46
  },
47
47
  "conventional-changelog": {
@@ -60,16 +60,16 @@
60
60
  "version": "0.17.1",
61
61
  "description": "TypeScript-specific rules for oxlint."
62
62
  },
63
- "prettier": {
64
- "version": "3.8.1",
65
- "description": "An opinionated code formatter."
63
+ "oxfmt": {
64
+ "version": "0.41.0",
65
+ "description": "High performance JavaScript / TypeScript formatter."
66
66
  },
67
67
  "typescript": {
68
68
  "version": "5.9.3",
69
69
  "description": "A superset of JavaScript that compiles to clean JavaScript output."
70
70
  },
71
71
  "vitest": {
72
- "version": "4.1.0",
72
+ "version": "4.1.1",
73
73
  "description": "A Vite-native unit test framework."
74
74
  },
75
75
  "commander": {
@@ -129,19 +129,19 @@
129
129
  "description": "End-to-end testing framework."
130
130
  },
131
131
  "@trpc/server": {
132
- "version": "11.14.1",
132
+ "version": "11.15.0",
133
133
  "description": "tRPC server library."
134
134
  },
135
135
  "@trpc/client": {
136
- "version": "11.14.1",
136
+ "version": "11.15.0",
137
137
  "description": "tRPC client library."
138
138
  },
139
139
  "@trpc/react-query": {
140
- "version": "11.14.1",
140
+ "version": "11.15.0",
141
141
  "description": "tRPC integration for React Query."
142
142
  },
143
143
  "@tanstack/react-query": {
144
- "version": "5.94.5",
144
+ "version": "5.95.2",
145
145
  "description": "Powerful asynchronous state management for TS/JS."
146
146
  },
147
147
  "zod": {
@@ -149,7 +149,7 @@
149
149
  "description": "TypeScript-first schema validation with static type inference."
150
150
  },
151
151
  "react-router-dom": {
152
- "version": "7.13.1",
152
+ "version": "7.13.2",
153
153
  "description": "Declarative routing for React web applications."
154
154
  },
155
155
  "cors": {