rapidkit 1.0.0-beta.4

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 ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 RapidKit
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,410 @@
1
+ # rapidkit
2
+
3
+ > ⚠️ **BETA VERSION** - This is a companion tool for RapidKit Python framework.
4
+ > The stable production version of RapidKit will be released soon on PyPI.
5
+ > Until then, use `--demo` mode to create demo workspaces with bundled templates, or `--test-mode` to try the full RapidKit installation locally.
6
+
7
+ 🚀 The easiest way to get started with RapidKit! This CLI tool creates development workspaces with two modes:
8
+
9
+ 1. **Demo Mode** (`--demo`) - Create a workspace with bundled FastAPI templates (no Python RapidKit required)
10
+ 2. **Full Mode** - Set up a Python environment with RapidKit installed (requires RapidKit on PyPI - coming soon!)
11
+
12
+ ## Quick Start
13
+
14
+ ### 🎨 Demo Mode (Available Now!)
15
+
16
+ Create a demo workspace and generate multiple FastAPI projects instantly:
17
+
18
+ ```bash
19
+ # Create demo workspace
20
+ npx rapidkit my-workspace --demo
21
+ cd my-workspace
22
+
23
+ # Generate your first project
24
+ node generate-demo.js api-project
25
+ cd api-project
26
+ poetry install
27
+ poetry run dev
28
+
29
+ # Go back and create more projects
30
+ cd ..
31
+ node generate-demo.js auth-service
32
+ node generate-demo.js data-service
33
+ ```
34
+
35
+ **Perfect for:**
36
+ - Quick prototyping and demos
37
+ - Learning FastAPI and RapidKit project structure
38
+ - Testing multiple microservices in one workspace
39
+ - No Python RapidKit dependency required
40
+ - **Try now while waiting for stable RapidKit release!**
41
+
42
+ ### 🚀 Full Mode (Coming Soon with Stable Release)
43
+
44
+ Once RapidKit is published on PyPI, install for full features and modules:
45
+
46
+ ```bash
47
+ npx rapidkit my-workspace
48
+ cd my-workspace
49
+ source $(poetry env info --path)/bin/activate
50
+ rapidkit create my-project
51
+ ```
52
+
53
+ **Note:** Full mode requires RapidKit Python package on PyPI.
54
+ For now, use `--test-mode` flag if you have local RapidKit installation, or use `--demo` for workspace with bundled templates.
55
+
56
+ ## Understanding Workspaces
57
+
58
+ **create-rapidkit** follows a workspace-based architecture:
59
+
60
+ - **Workspace** = Container directory with development environment
61
+ - **Projects** = Individual FastAPI/NestJS applications inside workspace
62
+
63
+ ### Demo Workspace Structure
64
+ ```
65
+ my-workspace/ # Workspace (container)
66
+ ├── generate-demo.js # Project generator script
67
+ ├── package.json # npm configuration
68
+ ├── README.md # Workspace instructions
69
+ ├── api-project/ # Project 1
70
+ │ ├── src/
71
+ │ ├── tests/
72
+ │ └── pyproject.toml
73
+ ├── auth-service/ # Project 2
74
+ │ ├── src/
75
+ │ ├── tests/
76
+ │ └── pyproject.toml
77
+ └── data-service/ # Project 3
78
+ ├── src/
79
+ ├── tests/
80
+ └── pyproject.toml
81
+ ```
82
+
83
+ ### Full Workspace Structure
84
+ ```
85
+ my-workspace/ # Workspace (container)
86
+ ├── .venv/ # Virtual environment
87
+ ├── pyproject.toml # Poetry config
88
+ ├── README.md # Workspace instructions
89
+ ├── api-project/ # Project 1
90
+ ├── auth-service/ # Project 2
91
+ └── data-service/ # Project 3
92
+ ```
93
+
94
+ **Benefits:**
95
+ - Multiple projects share same environment
96
+ - Easy microservices development
97
+ - Organized monorepo structure
98
+ - Isolated from system Python
99
+
100
+ ## Installation Methods
101
+
102
+ ### 🎯 Poetry (Recommended)
103
+ ```bash
104
+ npx rapidkit my-workspace
105
+ # Choose: Poetry
106
+ cd my-workspace
107
+ source $(poetry env info --path)/bin/activate
108
+ rapidkit create my-project
109
+ ```
110
+
111
+ ### 📦 Python venv + pip
112
+ ```bash
113
+ npx rapidkit my-workspace
114
+ # Select "venv + pip" when prompted
115
+ cd my-workspace
116
+ source .venv/bin/activate
117
+ rapidkit create my-project
118
+ ```
119
+
120
+ ### 🔧 pipx (Global)
121
+ ```bash
122
+ npx rapidkit my-workspace
123
+ # Select "pipx (global install)" when prompted
124
+ cd my-workspace
125
+ rapidkit create my-project
126
+ ```
127
+
128
+ ## What Gets Installed?
129
+
130
+ `rapidkit` creates a directory with:
131
+ - Python virtual environment (Poetry or venv)
132
+ - RapidKit package installed
133
+ - README with usage instructions
134
+ - Git repository (optional)
135
+
136
+ ## Using RapidKit Commands
137
+
138
+ Once your environment is activated, you can use all native RapidKit commands:
139
+
140
+ ```bash
141
+ # Create a new project (interactive)
142
+ rapidkit create
143
+
144
+ # Or create non-interactively:
145
+ rapidkit create project fastapi.standard my-api
146
+
147
+ # Add modules to existing project
148
+ cd my-api
149
+ rapidkit add settings
150
+ rapidkit add auth
151
+ rapidkit add database
152
+ rapidkit add caching
153
+
154
+ # List available kits and modules
155
+ rapidkit list
156
+ rapidkit modules
157
+
158
+ # Check system requirements
159
+ rapidkit doctor
160
+
161
+ # Upgrade RapidKit
162
+ rapidkit upgrade
163
+
164
+ # Get help
165
+ rapidkit --help
166
+ ```
167
+
168
+ ## Available Kits
169
+
170
+ RapidKit supports multiple project templates:
171
+ - `fastapi.standard` - FastAPI with basic features
172
+ - `fastapi.advanced` - FastAPI with advanced features
173
+ - `nestjs.standard` - NestJS with basic features
174
+ - `nestjs.advanced` - NestJS with advanced features
175
+
176
+ ## CLI Options
177
+
178
+ ```bash
179
+ npx rapidkit [workspace-name] [options]
180
+ ```
181
+
182
+ ### Arguments
183
+ - `workspace-name` - Name of workspace directory to create (default: `rapidkit-workspace`)
184
+
185
+ ### Options
186
+ - `--demo` - **[Available Now]** Create workspace with bundled FastAPI templates (no Python RapidKit required)
187
+ - `--demo-only` - **[Internal]** Generate a single project in current directory (used by demo workspace script)
188
+ - `--skip-git` - Skip git initialization
189
+ - `--test-mode` - **[Beta Testing]** Install from local RapidKit path (for development/testing only)
190
+ - `--help` - Display help information
191
+ - `--version` - Show version number
192
+
193
+ > **Note:** Full installation mode (without `--demo`) will be available once RapidKit is published on PyPI.
194
+
195
+ ## Examples
196
+
197
+ ### Demo Workspace
198
+ ```bash
199
+ # Create demo workspace
200
+ npx rapidkit my-workspace --demo
201
+ cd my-workspace
202
+
203
+ # Generate projects inside
204
+ node generate-demo.js api-service
205
+ node generate-demo.js auth-service
206
+ ```
207
+
208
+ ### Full RapidKit Workspace
209
+ ```bash
210
+ # Create workspace with RapidKit installed
211
+ npx rapidkit my-workspace
212
+ cd my-workspace
213
+
214
+ # Create projects using RapidKit CLI
215
+ rapidkit create api-service
216
+ rapidkit create auth-service
217
+ ```
218
+
219
+ ### Default workspace
220
+ ```bash
221
+ npx rapidkit --demo
222
+ # Creates ./rapidkit-workspace/ directory
223
+ ```
224
+
225
+ ### Skip git initialization
226
+ ```bash
227
+ npx rapidkit my-workspace --demo --skip-git
228
+ ```
229
+
230
+ ## Requirements
231
+
232
+ - **Node.js**: 18+ (for running npx)
233
+ - **Python**: 3.10+ (required by RapidKit)
234
+ - **Optional**: Poetry or pipx (depending on installation method)
235
+
236
+ ## Typical Workflow
237
+
238
+ ### Demo Mode
239
+ 1. **Create demo workspace**:
240
+ ```bash
241
+ npx rapidkit my-workspace --demo
242
+ cd my-workspace
243
+ ```
244
+
245
+ 2. **Generate your first project**:
246
+ ```bash
247
+ node generate-demo.js api-service
248
+ cd api-service
249
+ ```
250
+
251
+ 3. **Install dependencies and run**:
252
+ ```bash
253
+ poetry install
254
+ poetry run dev
255
+ ```
256
+
257
+ 4. **Create more projects** (go back to workspace):
258
+ ```bash
259
+ cd ..
260
+ node generate-demo.js auth-service
261
+ node generate-demo.js data-service
262
+ ```
263
+
264
+ ### Full Mode (After RapidKit PyPI Release)
265
+ 1. **Create RapidKit workspace**:
266
+ ```bash
267
+ npx rapidkit my-workspace
268
+ cd my-workspace
269
+ ```
270
+
271
+ 2. **Activate environment**:
272
+ ```bash
273
+ source $(poetry env info --path)/bin/activate
274
+ # Or: poetry shell
275
+ ```
276
+
277
+ 3. **Create your first project**:
278
+ ```bash
279
+ # Interactive mode (recommended)
280
+ rapidkit create
281
+
282
+ # Or specify directly:
283
+ rapidkit create project fastapi.standard api-service
284
+ ```
285
+
286
+ 4. **Navigate and run**:
287
+ ```bash
288
+ cd api-service
289
+ rapidkit run dev
290
+ ```
291
+
292
+ 5. **Create more projects** (from workspace root):
293
+ ```bash
294
+ cd ..
295
+ rapidkit create project fastapi.standard auth-service
296
+ rapidkit create project nestjs.standard data-service
297
+ ```
298
+
299
+ ## Troubleshooting
300
+
301
+ ### Python not found
302
+ ```bash
303
+ # Check Python version
304
+ python3 --version
305
+
306
+ # Install Python 3.10+
307
+ # Visit: https://www.python.org/downloads/
308
+ ```
309
+
310
+ ### Poetry not found
311
+ ```bash
312
+ # Install Poetry
313
+ curl -sSL https://install.python-poetry.org | python3 -
314
+
315
+ # Or visit: https://python-poetry.org/docs/#installation
316
+ ```
317
+
318
+ ### pipx not found
319
+ ```bash
320
+ # Install pipx
321
+ python3 -m pip install --user pipx
322
+ python3 -m pipx ensurepath
323
+
324
+ # Or visit: https://pypa.github.io/pipx/installation/
325
+ ```
326
+
327
+ ### Check RapidKit installation
328
+ ```bash
329
+ # Activate environment first
330
+ poetry shell # or: source .venv/bin/activate
331
+
332
+ # Verify RapidKit
333
+ rapidkit --version
334
+ rapidkit doctor
335
+ ```
336
+
337
+ ## What's Next?
338
+
339
+ After setting up your RapidKit environment:
340
+
341
+ ## What's Next?
342
+
343
+ After setting up your demo project:
344
+
345
+ 1. Explore the generated FastAPI structure
346
+ 2. Customize routes and add your business logic
347
+ 3. **Stay tuned for RapidKit stable release on PyPI**
348
+ 4. Upgrade to full RapidKit for modules and advanced features
349
+
350
+ ## Roadmap
351
+
352
+ ### ✅ Current (Beta)
353
+ - ✅ Demo workspace with bundled FastAPI templates
354
+ - ✅ Multiple projects per workspace
355
+ - ✅ Interactive project generation
356
+ - ✅ Full FastAPI project structure
357
+
358
+ ### 🚧 Coming Soon
359
+ - **RapidKit Python package on PyPI** (main blocker)
360
+ - Full installation mode with all kits
361
+ - Module ecosystem integration (`rapidkit add module`)
362
+ - NestJS standard kit demos
363
+ - Advanced kit templates
364
+ - Workspace sharing and templates
365
+
366
+ ### 🔮 Future
367
+ - More framework support
368
+ - Custom kit marketplace
369
+ - Cloud deployment integrations
370
+ - CI/CD templates
371
+
372
+ ## Related Projects
373
+
374
+ - **RapidKit Python** - The core framework (coming soon to PyPI)
375
+ - **RapidKit Marketplace** - Browse and share modules (https://rapidkit.dev)
376
+ - **GitHub**: https://github.com/getrapidkit
377
+
378
+ ## Contributing
379
+
380
+ Contributions welcome! This NPM package is a companion tool for RapidKit.
381
+
382
+ To contribute:
383
+ 1. Fork the repository
384
+ 2. Create a feature branch
385
+ 3. Submit a pull request
386
+
387
+ ## License
388
+
389
+ MIT
390
+
391
+ ## Support
392
+
393
+ - 🐛 Report issues: [GitHub Issues](https://github.com/getrapidkit/rapidkit-npm/issues)
394
+ - 📚 Docs: https://rapidkit.dev
395
+ - 💬 Community: Coming soon
396
+
397
+ ---
398
+
399
+ ### About This Beta
400
+
401
+ **rapidkit** (npm package) is currently in beta version 1.0.0-beta.4. The `--demo` mode is fully functional for creating workspaces with bundled FastAPI templates. You can generate multiple projects within the same workspace without needing Python RapidKit installed.
402
+
403
+ Install with:
404
+ ```bash
405
+ npx rapidkit my-workspace --demo
406
+ ```
407
+
408
+ **Full RapidKit integration** (with `rapidkit create` and `rapidkit add module` commands) will be available once the Python package is published on PyPI.
409
+
410
+ **Timeline**: RapidKit stable release expected soon. Follow [@getrapidkit](https://github.com/getrapidkit) for updates!
@@ -0,0 +1,8 @@
1
+ interface CreateProjectOptions {
2
+ skipGit?: boolean;
3
+ testMode?: boolean;
4
+ demoMode?: boolean;
5
+ }
6
+ export declare function createProject(projectName: string | undefined, options: CreateProjectOptions): Promise<void>;
7
+ export {};
8
+ //# sourceMappingURL=create.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../src/create.ts"],"names":[],"mappings":"AAQA,UAAU,oBAAoB;IAC5B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,wBAAsB,aAAa,CACjC,WAAW,EAAE,MAAM,GAAG,SAAS,EAC/B,OAAO,EAAE,oBAAoB,iBAgJ9B"}