saasforge 0.4.0__tar.gz

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.
Files changed (47) hide show
  1. saasforge-0.4.0/LICENSE +23 -0
  2. saasforge-0.4.0/NOTICE.md +13 -0
  3. saasforge-0.4.0/PKG-INFO +309 -0
  4. saasforge-0.4.0/README.md +293 -0
  5. saasforge-0.4.0/pyproject.toml +34 -0
  6. saasforge-0.4.0/saasforge/__init__.py +0 -0
  7. saasforge-0.4.0/saasforge/__main__.py +4 -0
  8. saasforge-0.4.0/saasforge/adapters/__init__.py +40 -0
  9. saasforge-0.4.0/saasforge/adapters/aider.py +42 -0
  10. saasforge-0.4.0/saasforge/adapters/antigravity.py +29 -0
  11. saasforge-0.4.0/saasforge/adapters/base.py +13 -0
  12. saasforge-0.4.0/saasforge/adapters/claude.py +22 -0
  13. saasforge-0.4.0/saasforge/adapters/codex.py +31 -0
  14. saasforge-0.4.0/saasforge/adapters/copilot.py +23 -0
  15. saasforge-0.4.0/saasforge/adapters/cursor.py +34 -0
  16. saasforge-0.4.0/saasforge/adapters/gemini.py +32 -0
  17. saasforge-0.4.0/saasforge/adapters/kilocode.py +36 -0
  18. saasforge-0.4.0/saasforge/adapters/opencode.py +74 -0
  19. saasforge-0.4.0/saasforge/adapters/openroutercli.py +39 -0
  20. saasforge-0.4.0/saasforge/adapters/qoder.py +25 -0
  21. saasforge-0.4.0/saasforge/adapters/qwen.py +31 -0
  22. saasforge-0.4.0/saasforge/adapters/roo.py +25 -0
  23. saasforge-0.4.0/saasforge/adapters/terminal.py +45 -0
  24. saasforge-0.4.0/saasforge/adapters/windsurf.py +30 -0
  25. saasforge-0.4.0/saasforge/builtins/constitution.md +18 -0
  26. saasforge-0.4.0/saasforge/builtins/specs/plan-template.md +20 -0
  27. saasforge-0.4.0/saasforge/builtins/specs/spec-template.md +31 -0
  28. saasforge-0.4.0/saasforge/builtins/specs/tasks-template.md +18 -0
  29. saasforge-0.4.0/saasforge/builtins/tool/Dockerfile.j2 +26 -0
  30. saasforge-0.4.0/saasforge/builtins/tool/app.py.j2 +14 -0
  31. saasforge-0.4.0/saasforge/builtins/tool/vercel.json.j2 +14 -0
  32. saasforge-0.4.0/saasforge/cli.py +354 -0
  33. saasforge-0.4.0/saasforge/config.py +79 -0
  34. saasforge-0.4.0/saasforge/dna_engine.py +82 -0
  35. saasforge-0.4.0/saasforge/memory.py +150 -0
  36. saasforge-0.4.0/saasforge/scaffold.py +58 -0
  37. saasforge-0.4.0/saasforge/templates.py +36 -0
  38. saasforge-0.4.0/saasforge.egg-info/PKG-INFO +309 -0
  39. saasforge-0.4.0/saasforge.egg-info/SOURCES.txt +45 -0
  40. saasforge-0.4.0/saasforge.egg-info/dependency_links.txt +1 -0
  41. saasforge-0.4.0/saasforge.egg-info/entry_points.txt +3 -0
  42. saasforge-0.4.0/saasforge.egg-info/requires.txt +3 -0
  43. saasforge-0.4.0/saasforge.egg-info/top_level.txt +1 -0
  44. saasforge-0.4.0/setup.cfg +4 -0
  45. saasforge-0.4.0/tests/test_cli.py +283 -0
  46. saasforge-0.4.0/tests/test_dna_engine.py +121 -0
  47. saasforge-0.4.0/tests/test_memory.py +98 -0
@@ -0,0 +1,23 @@
1
+ SaaSForge Commercial License
2
+ Copyright (c) 2026 Fahad Khakwani
3
+
4
+ All rights reserved.
5
+
6
+ This license governs the use of SaaSForge, the Spec-Driven Micro-SaaS
7
+ Development Toolkit.
8
+
9
+ 1. **Grant of License:** Permission is hereby granted to use, copy, modify,
10
+ and distribute this software for internal business purposes only.
11
+
12
+ 2. **Restrictions:**
13
+ a) You may not redistribute this software as a stand-alone product.
14
+ b) You may not sublicense, rent, or lease this software.
15
+ c) You may not remove or alter any copyright notices.
16
+
17
+ 3. **Commercial Use:** Commercial use requires a separate paid license.
18
+ Contact: fahadyousufkhakwani@gmail.com
19
+
20
+ 4. **Disclaimer:** This software is provided "as is", without warranty of any
21
+ kind, express or implied.
22
+
23
+ 5. **Notices:** See NOTICE.md for third-party attributions (SpecifyPlus MIT).
@@ -0,0 +1,13 @@
1
+ # NOTICE
2
+
3
+ ## SaaSForge — Spec-Driven Micro-SaaS Development Toolkit
4
+
5
+ Copyright (c) 2026 Fahad Khakwani. All rights reserved.
6
+
7
+ This product is based on SpecifyPlus:
8
+ - Original: https://github.com/panaversity/spec-kit-plus
9
+ - Copyright (c) GitHub, Inc.
10
+ - Licensed under MIT License — see LICENSE.ORIGINAL in original distribution
11
+
12
+ Modifications, enhancements, and additional features are original to SaaSForge
13
+ and are subject to the SaaSForge Commercial License (see LICENSE).
@@ -0,0 +1,309 @@
1
+ Metadata-Version: 2.4
2
+ Name: saasforge
3
+ Version: 0.4.0
4
+ Summary: Spec-Driven Micro-SaaS Development Toolkit
5
+ Author-email: Fahad Khakwani <fahadyousufkhakwani@gmail.com>
6
+ License: SaaSForge Commercial License
7
+ Project-URL: Homepage, https://github.com/Fahad-FullStackDeveloper/saasforge
8
+ Requires-Python: >=3.11
9
+ Description-Content-Type: text/markdown
10
+ License-File: LICENSE
11
+ License-File: NOTICE.md
12
+ Requires-Dist: typer>=0.12
13
+ Requires-Dist: rich>=13
14
+ Requires-Dist: jinja2>=3
15
+ Dynamic: license-file
16
+
17
+ # SaaSForge
18
+
19
+ **Build 450+ Micro-SaaS tools with one DNA-driven workflow.**
20
+ AI-native, spec-driven, deploy-ready.
21
+
22
+ ```
23
+ pip install saasforge
24
+ ```
25
+
26
+ ---
27
+
28
+ ## What is SaaSForge?
29
+
30
+ SaaSForge is a Spec-Driven Micro-SaaS Development Toolkit. It lets you:
31
+
32
+ - **Scaffold** full-stack Micro-SaaS tools from a single DNA architecture document
33
+ - **Work with any AI CLI** — opencode, Claude Code, Gemini CLI, Copilot, Cursor, Aider, KiloCode, and more
34
+ - **Track decisions** via an auto-generated constitution and command history
35
+ - **Deploy** to Vercel (frontend) + Hugging Face Spaces (backend) with one checklist
36
+
37
+ Unlike general-purpose scaffolding tools, SaaSForge is **DNA-aware**: it reads your `_system/DNA.md` and generates tools that match your exact tech stack (FastAPI, Turso, Better Auth, R2, etc.).
38
+
39
+ ---
40
+
41
+ ## Quick Start
42
+
43
+ ```bash
44
+ # Check your environment
45
+ saasforge check
46
+
47
+ # Initialize a new project
48
+ saasforge init my-micro-saas --ai opencode
49
+
50
+ # Generate workflow commands
51
+ cd my-micro-saas
52
+ saasforge workflow --ai opencode
53
+
54
+ # View your project constitution
55
+ saasforge constitute --show
56
+
57
+ # See what commands you've run
58
+ saasforge history
59
+ ```
60
+
61
+ ---
62
+
63
+ ## Full Workflow
64
+
65
+ ### 1. Define Your DNA
66
+
67
+ Create `_system/DNA.md` with your architecture:
68
+
69
+ ```markdown
70
+ FRONTEND: Next.js + Tailwind + Shadcn → Vercel
71
+ BACKEND: Python FastAPI → Hugging Face Spaces
72
+ DATABASE: Turso SQLite
73
+ AUTH: Better Auth
74
+ FILE STORAGE: Cloudflare R2
75
+ ```
76
+
77
+ SaaSForge parses this — case-insensitive, spaces-before-colon, aliases all work:
78
+
79
+ ```markdown
80
+ FrontEnd : nextjs ✓
81
+ DB : postgres ✓ (alias works)
82
+ File Storage : R2 ✓
83
+ ```
84
+
85
+ Validate: `saasforge dna --validate`
86
+
87
+ ### 2. Initialize
88
+
89
+ ```bash
90
+ # With any supported AI CLI
91
+ saasforge init . --ai opencode # Current dir
92
+ saasforge init my-tool --ai claude # New folder
93
+
94
+ # Plain terminal (no AI CLI needed)
95
+ saasforge init my-tool --ai terminal
96
+ ```
97
+
98
+ This creates adapter config files for your chosen CLI.
99
+
100
+ ### 3. Scaffold a Tool
101
+
102
+ ```bash
103
+ saasforge scaffold whatsapp-bot --number 002 --dna _system/DNA.md
104
+ ```
105
+
106
+ Generates:
107
+
108
+ ```
109
+ _tools/
110
+ └── _002-whatsapp-bot/
111
+ ├── frontend/
112
+ ├── backend/
113
+ │ ├── api/
114
+ │ └── src/
115
+ ├── tests/
116
+ ├── Dockerfile
117
+ ├── .dockerignore
118
+ ├── app.py
119
+ ├── requirements.txt
120
+ └── vercel.json
121
+ ```
122
+
123
+ Use `--force` to overwrite an existing tool.
124
+
125
+ ### 4. Track Context (Constitution)
126
+
127
+ ```bash
128
+ # Show current constitution
129
+ saasforge constitute --show
130
+
131
+ # Regenerate from DNA
132
+ saasforge constitute --regenerate
133
+
134
+ # Open in editor
135
+ saasforge constitute --edit
136
+ ```
137
+
138
+ The constitution lives in `.saasforge/memory/constitution.md` — AI CLIs read it at session start for continuity.
139
+
140
+ ### 5. Generate Workflow Commands
141
+
142
+ ```bash
143
+ saasforge workflow --ai opencode
144
+ ```
145
+
146
+ Creates slash commands in `.opencode/commands/`:
147
+
148
+ | Command | Purpose |
149
+ |---------|---------|
150
+ | `/sp.specify` | Define what to build |
151
+ | `/sp.plan` | Create implementation plan |
152
+ | `/sp.tasks` | Break into actionable tasks |
153
+ | `/sp.implement` | Execute the plan |
154
+ | `/sp.analyze` | Cross-artifact consistency check |
155
+
156
+ ### 6. Deploy
157
+
158
+ ```bash
159
+ saasforge deploy ./_tools/_002-whatsapp-bot
160
+ ```
161
+
162
+ Shows a readiness checklist:
163
+
164
+ | Item | Tool 001 |
165
+ |------|----------|
166
+ | Dockerfile | ✓ |
167
+ | app.py | ✓ |
168
+ | vercel.json | ✓ |
169
+ | frontend/ | ✓ |
170
+ | backend/ | ✓ |
171
+
172
+ ---
173
+
174
+ ## Supported AI CLIs (15)
175
+
176
+ | CLI | Flag | Generates |
177
+ |-----|------|-----------|
178
+ | opencode | `--ai opencode` | `.opencode/commands/` |
179
+ | Claude Code | `--ai claude` | `.claude/commands/` |
180
+ | Gemini CLI | `--ai gemini` | `.gemini/` |
181
+ | GitHub Copilot | `--ai copilot` | `.github/instructions/` |
182
+ | Cursor | `--ai cursor` | `.cursor/rules/` |
183
+ | Windsurf | `--ai windsurf` | `.windsurf/` rules |
184
+ | Roo Code | `--ai roo` | `.roo/commands/` |
185
+ | Codex CLI | `--ai codex` | `.codex/instructions/` |
186
+ | Qwen Code | `--ai qwen` | `.qwen/` workflow |
187
+ | Qoder CLI | `--ai qoder` | `.qoder/commands/` |
188
+ | Antigravity | `--ai antigravity` | `.antigravity/rules/` |
189
+ | Aider | `--ai aider` | `.aider/CONVENTIONS.md` |
190
+ | KiloCode | `--ai kilocode` | `.kilocode/instructions/` |
191
+ | OpenRouter CLI | `--ai openroutercli` | `.openrouter/` |
192
+ | Terminal | `--ai terminal` | `.saasforge/config.yml` |
193
+
194
+ ---
195
+
196
+ ## Commands Reference
197
+
198
+ | Command | Description |
199
+ |---------|-------------|
200
+ | `check` | Check installed tools (git, python, pnpm, etc.) |
201
+ | `init` | Initialize project with AI CLI adapter config |
202
+ | `scaffold` | Generate full tool structure from DNA |
203
+ | `workflow` | Generate spec-driven slash commands for your CLI |
204
+ | `deploy` | Show deployment readiness checklist |
205
+ | `dna` | Inspect and validate DNA.md |
206
+ | `constitute` | Manage project constitution (memory for AI CLI) |
207
+ | `history` | View or clear command history |
208
+
209
+ ### Options
210
+
211
+ | Flag | Commands | Purpose |
212
+ |------|----------|---------|
213
+ | `--ai` | init, workflow | Choose AI CLI adapter |
214
+ | `--no-git` | init | Skip git init |
215
+ | `--here` | init | Init in current directory |
216
+ | `--force`, `-f` | scaffold | Overwrite existing tool |
217
+ | `--number`, `-n` | scaffold | Tool number (default: 002) |
218
+ | `--show`, `-s` | constitute | Display constitution |
219
+ | `--edit`, `-e` | constitute | Edit in default editor |
220
+ | `--regenerate`, `-r` | constitute | Regenerate from DNA |
221
+ | `--limit`, `-n` | history | Entry count (default: 50) |
222
+ | `--clear` | history | Delete all history |
223
+ | `--validate` | dna | Run validation checks |
224
+ | `--version`, `-v` | (global) | Show version |
225
+
226
+ ---
227
+
228
+ ## Use Cases
229
+
230
+ ### Solo Founder — Micro-SaaS Factory
231
+
232
+ Build 1 tool per week using the same DNA. Each tool gets its own Vercel project, HF Space, Turso DB, and R2 bucket — completely isolated, zero shared infrastructure.
233
+
234
+ ```bash
235
+ saasforge scaffold invoice-ocr --number 001
236
+ saasforge scaffold whatsapp-bot --number 002
237
+ saasforge scaffold blog-writer --number 003
238
+ ```
239
+
240
+ ### Team — Standardized Architecture
241
+
242
+ Onboard new developers quickly. DNA.md is the single source of truth. Everyone uses the same stack, same patterns, same deployment flow.
243
+
244
+ ### AI-Only Development
245
+
246
+ Use `--ai terminal` — no AI CLI required. The `.saasforge/config.yml` file stores your project config. Run `saasforge workflow --ai terminal` to generate instructions that any LLM can follow.
247
+
248
+ ### Education — Learn Full-Stack SaaS
249
+
250
+ Scaffold a complete SaaS tool structure in seconds. Study the generated Dockerfile, FastAPI backend, Next.js frontend, and deployment config.
251
+
252
+ ---
253
+
254
+ ## Comparison: SaaSForge vs SpecifyPlus
255
+
256
+ | Capability | SpecifyPlus | SaaSForge |
257
+ |------------|-------------|-----------|
258
+ | **DNA-aware scaffolding** | ❌ Static templates | ✅ Reads `_system/DNA.md` |
259
+ | **CLI adapters** | 18 | 15 (terminal included) |
260
+ | **Deploy guide** | ❌ | ✅ Vercel + HF Spaces |
261
+ | **DNA validation** | ❌ | ✅ `saasforge dna --validate` |
262
+ | **Command history** | ❌ | ✅ `.saasforge/memory/history.yml` |
263
+ | **Constitution** | ✅ `.specify/memory/` | ✅ `.saasforge/memory/constitution.md` |
264
+ | **`check` command** | ✅ `specifyplus check` | ✅ `saasforge check` |
265
+ | **Scaffold `--force`** | ❌ (silent overwrite) | ✅ Explicit flag |
266
+ | **DNA parser** | Exact match only | ✅ Case-insensitive, aliases, regex |
267
+ | **Terminal-only mode** | ❌ | ✅ `--ai terminal` |
268
+ | **License** | MIT | Commercial + MIT credit (NOTICE.md) |
269
+ | **Target** | General spec-driven dev | Micro-SaaS factory (450 tools) |
270
+
271
+ ---
272
+
273
+ ## Architecture
274
+
275
+ ```
276
+ project-root/
277
+ ├── _system/
278
+ │ └── DNA.md ← Single source of truth
279
+ ├── _tools/
280
+ │ ├── _001-invoice-ocr/ ← Isolated Micro-SaaS tool
281
+ │ │ ├── frontend/ (Next.js)
282
+ │ │ ├── backend/ (FastAPI)
283
+ │ │ ├── Dockerfile
284
+ │ │ └── app.py
285
+ │ ├── _002-whatsapp-bot/
286
+ │ └── _003-blog-writer/
287
+ ├── .saasforge/
288
+ │ └── memory/
289
+ │ ├── constitution.md ← Project memory for AI CLI
290
+ │ └── history.yml ← Command audit trail
291
+ └── saasforge ← CLI tool
292
+ ```
293
+
294
+ Each tool is independently deployable:
295
+
296
+ ```
297
+ Tool 001 → Vercel (FE) + HF Space (BE) + Turso DB + R2 Bucket
298
+ Tool 002 → Vercel (FE) + HF Space (BE) + Turso DB + R2 Bucket
299
+ ...
300
+ ```
301
+
302
+ ---
303
+
304
+ ## License
305
+
306
+ - Original SpecifyPlus code: MIT © GitHub, Inc. — see NOTICE.md
307
+ - All new code, adapters, CLI, templates, and SaaSForge-specific work: **SaaSForge Commercial License** — see LICENSE
308
+
309
+ You may use SaaSForge freely in your own projects. Contact the author for commercial redistribution or licensing.
@@ -0,0 +1,293 @@
1
+ # SaaSForge
2
+
3
+ **Build 450+ Micro-SaaS tools with one DNA-driven workflow.**
4
+ AI-native, spec-driven, deploy-ready.
5
+
6
+ ```
7
+ pip install saasforge
8
+ ```
9
+
10
+ ---
11
+
12
+ ## What is SaaSForge?
13
+
14
+ SaaSForge is a Spec-Driven Micro-SaaS Development Toolkit. It lets you:
15
+
16
+ - **Scaffold** full-stack Micro-SaaS tools from a single DNA architecture document
17
+ - **Work with any AI CLI** — opencode, Claude Code, Gemini CLI, Copilot, Cursor, Aider, KiloCode, and more
18
+ - **Track decisions** via an auto-generated constitution and command history
19
+ - **Deploy** to Vercel (frontend) + Hugging Face Spaces (backend) with one checklist
20
+
21
+ Unlike general-purpose scaffolding tools, SaaSForge is **DNA-aware**: it reads your `_system/DNA.md` and generates tools that match your exact tech stack (FastAPI, Turso, Better Auth, R2, etc.).
22
+
23
+ ---
24
+
25
+ ## Quick Start
26
+
27
+ ```bash
28
+ # Check your environment
29
+ saasforge check
30
+
31
+ # Initialize a new project
32
+ saasforge init my-micro-saas --ai opencode
33
+
34
+ # Generate workflow commands
35
+ cd my-micro-saas
36
+ saasforge workflow --ai opencode
37
+
38
+ # View your project constitution
39
+ saasforge constitute --show
40
+
41
+ # See what commands you've run
42
+ saasforge history
43
+ ```
44
+
45
+ ---
46
+
47
+ ## Full Workflow
48
+
49
+ ### 1. Define Your DNA
50
+
51
+ Create `_system/DNA.md` with your architecture:
52
+
53
+ ```markdown
54
+ FRONTEND: Next.js + Tailwind + Shadcn → Vercel
55
+ BACKEND: Python FastAPI → Hugging Face Spaces
56
+ DATABASE: Turso SQLite
57
+ AUTH: Better Auth
58
+ FILE STORAGE: Cloudflare R2
59
+ ```
60
+
61
+ SaaSForge parses this — case-insensitive, spaces-before-colon, aliases all work:
62
+
63
+ ```markdown
64
+ FrontEnd : nextjs ✓
65
+ DB : postgres ✓ (alias works)
66
+ File Storage : R2 ✓
67
+ ```
68
+
69
+ Validate: `saasforge dna --validate`
70
+
71
+ ### 2. Initialize
72
+
73
+ ```bash
74
+ # With any supported AI CLI
75
+ saasforge init . --ai opencode # Current dir
76
+ saasforge init my-tool --ai claude # New folder
77
+
78
+ # Plain terminal (no AI CLI needed)
79
+ saasforge init my-tool --ai terminal
80
+ ```
81
+
82
+ This creates adapter config files for your chosen CLI.
83
+
84
+ ### 3. Scaffold a Tool
85
+
86
+ ```bash
87
+ saasforge scaffold whatsapp-bot --number 002 --dna _system/DNA.md
88
+ ```
89
+
90
+ Generates:
91
+
92
+ ```
93
+ _tools/
94
+ └── _002-whatsapp-bot/
95
+ ├── frontend/
96
+ ├── backend/
97
+ │ ├── api/
98
+ │ └── src/
99
+ ├── tests/
100
+ ├── Dockerfile
101
+ ├── .dockerignore
102
+ ├── app.py
103
+ ├── requirements.txt
104
+ └── vercel.json
105
+ ```
106
+
107
+ Use `--force` to overwrite an existing tool.
108
+
109
+ ### 4. Track Context (Constitution)
110
+
111
+ ```bash
112
+ # Show current constitution
113
+ saasforge constitute --show
114
+
115
+ # Regenerate from DNA
116
+ saasforge constitute --regenerate
117
+
118
+ # Open in editor
119
+ saasforge constitute --edit
120
+ ```
121
+
122
+ The constitution lives in `.saasforge/memory/constitution.md` — AI CLIs read it at session start for continuity.
123
+
124
+ ### 5. Generate Workflow Commands
125
+
126
+ ```bash
127
+ saasforge workflow --ai opencode
128
+ ```
129
+
130
+ Creates slash commands in `.opencode/commands/`:
131
+
132
+ | Command | Purpose |
133
+ |---------|---------|
134
+ | `/sp.specify` | Define what to build |
135
+ | `/sp.plan` | Create implementation plan |
136
+ | `/sp.tasks` | Break into actionable tasks |
137
+ | `/sp.implement` | Execute the plan |
138
+ | `/sp.analyze` | Cross-artifact consistency check |
139
+
140
+ ### 6. Deploy
141
+
142
+ ```bash
143
+ saasforge deploy ./_tools/_002-whatsapp-bot
144
+ ```
145
+
146
+ Shows a readiness checklist:
147
+
148
+ | Item | Tool 001 |
149
+ |------|----------|
150
+ | Dockerfile | ✓ |
151
+ | app.py | ✓ |
152
+ | vercel.json | ✓ |
153
+ | frontend/ | ✓ |
154
+ | backend/ | ✓ |
155
+
156
+ ---
157
+
158
+ ## Supported AI CLIs (15)
159
+
160
+ | CLI | Flag | Generates |
161
+ |-----|------|-----------|
162
+ | opencode | `--ai opencode` | `.opencode/commands/` |
163
+ | Claude Code | `--ai claude` | `.claude/commands/` |
164
+ | Gemini CLI | `--ai gemini` | `.gemini/` |
165
+ | GitHub Copilot | `--ai copilot` | `.github/instructions/` |
166
+ | Cursor | `--ai cursor` | `.cursor/rules/` |
167
+ | Windsurf | `--ai windsurf` | `.windsurf/` rules |
168
+ | Roo Code | `--ai roo` | `.roo/commands/` |
169
+ | Codex CLI | `--ai codex` | `.codex/instructions/` |
170
+ | Qwen Code | `--ai qwen` | `.qwen/` workflow |
171
+ | Qoder CLI | `--ai qoder` | `.qoder/commands/` |
172
+ | Antigravity | `--ai antigravity` | `.antigravity/rules/` |
173
+ | Aider | `--ai aider` | `.aider/CONVENTIONS.md` |
174
+ | KiloCode | `--ai kilocode` | `.kilocode/instructions/` |
175
+ | OpenRouter CLI | `--ai openroutercli` | `.openrouter/` |
176
+ | Terminal | `--ai terminal` | `.saasforge/config.yml` |
177
+
178
+ ---
179
+
180
+ ## Commands Reference
181
+
182
+ | Command | Description |
183
+ |---------|-------------|
184
+ | `check` | Check installed tools (git, python, pnpm, etc.) |
185
+ | `init` | Initialize project with AI CLI adapter config |
186
+ | `scaffold` | Generate full tool structure from DNA |
187
+ | `workflow` | Generate spec-driven slash commands for your CLI |
188
+ | `deploy` | Show deployment readiness checklist |
189
+ | `dna` | Inspect and validate DNA.md |
190
+ | `constitute` | Manage project constitution (memory for AI CLI) |
191
+ | `history` | View or clear command history |
192
+
193
+ ### Options
194
+
195
+ | Flag | Commands | Purpose |
196
+ |------|----------|---------|
197
+ | `--ai` | init, workflow | Choose AI CLI adapter |
198
+ | `--no-git` | init | Skip git init |
199
+ | `--here` | init | Init in current directory |
200
+ | `--force`, `-f` | scaffold | Overwrite existing tool |
201
+ | `--number`, `-n` | scaffold | Tool number (default: 002) |
202
+ | `--show`, `-s` | constitute | Display constitution |
203
+ | `--edit`, `-e` | constitute | Edit in default editor |
204
+ | `--regenerate`, `-r` | constitute | Regenerate from DNA |
205
+ | `--limit`, `-n` | history | Entry count (default: 50) |
206
+ | `--clear` | history | Delete all history |
207
+ | `--validate` | dna | Run validation checks |
208
+ | `--version`, `-v` | (global) | Show version |
209
+
210
+ ---
211
+
212
+ ## Use Cases
213
+
214
+ ### Solo Founder — Micro-SaaS Factory
215
+
216
+ Build 1 tool per week using the same DNA. Each tool gets its own Vercel project, HF Space, Turso DB, and R2 bucket — completely isolated, zero shared infrastructure.
217
+
218
+ ```bash
219
+ saasforge scaffold invoice-ocr --number 001
220
+ saasforge scaffold whatsapp-bot --number 002
221
+ saasforge scaffold blog-writer --number 003
222
+ ```
223
+
224
+ ### Team — Standardized Architecture
225
+
226
+ Onboard new developers quickly. DNA.md is the single source of truth. Everyone uses the same stack, same patterns, same deployment flow.
227
+
228
+ ### AI-Only Development
229
+
230
+ Use `--ai terminal` — no AI CLI required. The `.saasforge/config.yml` file stores your project config. Run `saasforge workflow --ai terminal` to generate instructions that any LLM can follow.
231
+
232
+ ### Education — Learn Full-Stack SaaS
233
+
234
+ Scaffold a complete SaaS tool structure in seconds. Study the generated Dockerfile, FastAPI backend, Next.js frontend, and deployment config.
235
+
236
+ ---
237
+
238
+ ## Comparison: SaaSForge vs SpecifyPlus
239
+
240
+ | Capability | SpecifyPlus | SaaSForge |
241
+ |------------|-------------|-----------|
242
+ | **DNA-aware scaffolding** | ❌ Static templates | ✅ Reads `_system/DNA.md` |
243
+ | **CLI adapters** | 18 | 15 (terminal included) |
244
+ | **Deploy guide** | ❌ | ✅ Vercel + HF Spaces |
245
+ | **DNA validation** | ❌ | ✅ `saasforge dna --validate` |
246
+ | **Command history** | ❌ | ✅ `.saasforge/memory/history.yml` |
247
+ | **Constitution** | ✅ `.specify/memory/` | ✅ `.saasforge/memory/constitution.md` |
248
+ | **`check` command** | ✅ `specifyplus check` | ✅ `saasforge check` |
249
+ | **Scaffold `--force`** | ❌ (silent overwrite) | ✅ Explicit flag |
250
+ | **DNA parser** | Exact match only | ✅ Case-insensitive, aliases, regex |
251
+ | **Terminal-only mode** | ❌ | ✅ `--ai terminal` |
252
+ | **License** | MIT | Commercial + MIT credit (NOTICE.md) |
253
+ | **Target** | General spec-driven dev | Micro-SaaS factory (450 tools) |
254
+
255
+ ---
256
+
257
+ ## Architecture
258
+
259
+ ```
260
+ project-root/
261
+ ├── _system/
262
+ │ └── DNA.md ← Single source of truth
263
+ ├── _tools/
264
+ │ ├── _001-invoice-ocr/ ← Isolated Micro-SaaS tool
265
+ │ │ ├── frontend/ (Next.js)
266
+ │ │ ├── backend/ (FastAPI)
267
+ │ │ ├── Dockerfile
268
+ │ │ └── app.py
269
+ │ ├── _002-whatsapp-bot/
270
+ │ └── _003-blog-writer/
271
+ ├── .saasforge/
272
+ │ └── memory/
273
+ │ ├── constitution.md ← Project memory for AI CLI
274
+ │ └── history.yml ← Command audit trail
275
+ └── saasforge ← CLI tool
276
+ ```
277
+
278
+ Each tool is independently deployable:
279
+
280
+ ```
281
+ Tool 001 → Vercel (FE) + HF Space (BE) + Turso DB + R2 Bucket
282
+ Tool 002 → Vercel (FE) + HF Space (BE) + Turso DB + R2 Bucket
283
+ ...
284
+ ```
285
+
286
+ ---
287
+
288
+ ## License
289
+
290
+ - Original SpecifyPlus code: MIT © GitHub, Inc. — see NOTICE.md
291
+ - All new code, adapters, CLI, templates, and SaaSForge-specific work: **SaaSForge Commercial License** — see LICENSE
292
+
293
+ You may use SaaSForge freely in your own projects. Contact the author for commercial redistribution or licensing.
@@ -0,0 +1,34 @@
1
+ [project]
2
+ name = "saasforge"
3
+ version = "0.4.0"
4
+ description = "Spec-Driven Micro-SaaS Development Toolkit"
5
+ readme = "README.md"
6
+ requires-python = ">=3.11"
7
+ license = { text = "SaaSForge Commercial License" }
8
+ authors = [
9
+ { name = "Fahad Khakwani", email = "fahadyousufkhakwani@gmail.com" },
10
+ ]
11
+ dependencies = [
12
+ "typer>=0.12",
13
+ "rich>=13",
14
+ "jinja2>=3",
15
+ ]
16
+
17
+ [project.urls]
18
+ Homepage = "https://github.com/Fahad-FullStackDeveloper/saasforge"
19
+
20
+ [project.scripts]
21
+ saasforge = "saasforge.cli:app"
22
+ sp = "saasforge.cli:app"
23
+
24
+ [build-system]
25
+ requires = ["setuptools>=75"]
26
+ build-backend = "setuptools.build_meta"
27
+
28
+ [tool.setuptools.packages.find]
29
+ include = ["saasforge*"]
30
+
31
+ [tool.setuptools.package-data]
32
+ "saasforge.builtins" = ["**/*"]
33
+ "saasforge.builtins.tool" = ["**/*"]
34
+ "saasforge.builtins.specs" = ["**/*"]
File without changes
@@ -0,0 +1,4 @@
1
+ from .cli import app
2
+
3
+ if __name__ == "__main__":
4
+ app()