specchain-pro 0.1.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.
@@ -0,0 +1,443 @@
1
+ # Deploy SpecChain Pro Without npm
2
+
3
+ You can deploy and use SpecChain Pro without publishing to npm. Here are your options:
4
+
5
+ ## 🎯 Deployment Options (No npm Required)
6
+
7
+ ### Option 1: GitHub Only (Recommended)
8
+ ### Option 2: Local Installation
9
+ ### Option 3: Docker Container
10
+ ### Option 4: Direct Distribution
11
+
12
+ ---
13
+
14
+ ## 📦 Option 1: GitHub Only Deployment
15
+
16
+ Deploy to GitHub and users install directly from your repository.
17
+
18
+ ### Step 1: Push to GitHub
19
+
20
+ ```bash
21
+ # Initialize git
22
+ git init
23
+ git add .
24
+ git commit -m "Initial release v0.1.0"
25
+
26
+ # Create GitHub repository, then:
27
+ git remote add origin https://github.com/yourusername/specchain-pro.git
28
+ git branch -M main
29
+ git push -u origin main
30
+
31
+ # Create release tag
32
+ git tag -a v0.1.0 -m "Release v0.1.0: MVP Base"
33
+ git push origin v0.1.0
34
+ ```
35
+
36
+ ### Step 2: Users Install from GitHub
37
+
38
+ Users can install directly from your GitHub repository:
39
+
40
+ ```bash
41
+ # Install globally from GitHub
42
+ npm install -g github:yourusername/specchain-pro
43
+
44
+ # Or install from specific branch
45
+ npm install -g github:yourusername/specchain-pro#main
46
+
47
+ # Or install from specific tag/release
48
+ npm install -g github:yourusername/specchain-pro#v0.1.0
49
+ ```
50
+
51
+ ### Step 3: Create GitHub Release
52
+
53
+ 1. Go to: https://github.com/yourusername/specchain-pro/releases/new
54
+ 2. Select tag: `v0.1.0`
55
+ 3. Title: `v0.1.0 - MVP Base Foundation`
56
+ 4. Add release notes from CHANGELOG.md
57
+ 5. Attach compiled binaries (optional)
58
+
59
+ ### Advantages
60
+ - ✅ Free hosting
61
+ - ✅ Version control built-in
62
+ - ✅ Issue tracking
63
+ - ✅ Community contributions
64
+ - ✅ No npm account needed
65
+
66
+ ### Installation Instructions for Users
67
+
68
+ Add this to your README.md:
69
+
70
+ ```markdown
71
+ ## Installation
72
+
73
+ Install directly from GitHub:
74
+
75
+ ```bash
76
+ npm install -g github:yourusername/specchain-pro
77
+ ```
78
+
79
+ Or clone and install locally:
80
+
81
+ ```bash
82
+ git clone https://github.com/yourusername/specchain-pro.git
83
+ cd specchain-pro
84
+ npm install
85
+ npm run build
86
+ npm link
87
+ ```
88
+ ```
89
+
90
+ ---
91
+
92
+ ## 🏠 Option 2: Local Installation Only
93
+
94
+ Keep it on your machine or share with your team.
95
+
96
+ ### For Your Own Use
97
+
98
+ ```bash
99
+ # Build the project
100
+ npm run build
101
+
102
+ # Link globally on your machine
103
+ npm link
104
+
105
+ # Now you can use 'spec' command anywhere
106
+ spec --help
107
+ spec --version
108
+ ```
109
+
110
+ ### For Your Team
111
+
112
+ Share the repository with your team:
113
+
114
+ ```bash
115
+ # Team members clone the repo
116
+ git clone https://github.com/yourusername/specchain-pro.git
117
+ cd specchain-pro
118
+
119
+ # Install dependencies
120
+ npm install
121
+
122
+ # Build
123
+ npm run build
124
+
125
+ # Link globally
126
+ npm link
127
+
128
+ # Now everyone can use 'spec' command
129
+ spec --help
130
+ ```
131
+
132
+ ### Advantages
133
+ - ✅ Complete control
134
+ - ✅ No public exposure
135
+ - ✅ Easy to modify
136
+ - ✅ No deployment needed
137
+
138
+ ---
139
+
140
+ ## 🐳 Option 3: Docker Container
141
+
142
+ Package as a Docker container for easy distribution.
143
+
144
+ ### Create Dockerfile
145
+
146
+ ```dockerfile
147
+ FROM node:18-alpine
148
+
149
+ WORKDIR /app
150
+
151
+ # Copy package files
152
+ COPY package*.json ./
153
+
154
+ # Install dependencies
155
+ RUN npm ci --only=production
156
+
157
+ # Copy source and build
158
+ COPY . .
159
+ RUN npm run build
160
+
161
+ # Create symlink for CLI
162
+ RUN npm link
163
+
164
+ # Set entrypoint
165
+ ENTRYPOINT ["spec"]
166
+ CMD ["--help"]
167
+ ```
168
+
169
+ ### Build and Run
170
+
171
+ ```bash
172
+ # Build Docker image
173
+ docker build -t specchain-pro:0.1.0 .
174
+
175
+ # Run commands
176
+ docker run specchain-pro:0.1.0 --version
177
+ docker run specchain-pro:0.1.0 new "Your idea"
178
+
179
+ # Create alias for easier use
180
+ alias spec='docker run -v ~/.specchain:/root/.specchain specchain-pro:0.1.0'
181
+
182
+ # Now use like normal CLI
183
+ spec --help
184
+ spec new "Your idea"
185
+ ```
186
+
187
+ ### Share Docker Image
188
+
189
+ ```bash
190
+ # Save image to file
191
+ docker save specchain-pro:0.1.0 > specchain-pro.tar
192
+
193
+ # Share the .tar file with others
194
+ # They can load it:
195
+ docker load < specchain-pro.tar
196
+
197
+ # Or push to Docker Hub (free)
198
+ docker tag specchain-pro:0.1.0 yourusername/specchain-pro:0.1.0
199
+ docker push yourusername/specchain-pro:0.1.0
200
+
201
+ # Users install:
202
+ docker pull yourusername/specchain-pro:0.1.0
203
+ ```
204
+
205
+ ### Advantages
206
+ - ✅ Consistent environment
207
+ - ✅ Easy distribution
208
+ - ✅ No Node.js required for users
209
+ - ✅ Isolated from system
210
+
211
+ ---
212
+
213
+ ## 📁 Option 4: Direct Distribution
214
+
215
+ Share compiled files directly.
216
+
217
+ ### Create Distribution Package
218
+
219
+ ```bash
220
+ # Build the project
221
+ npm run build
222
+
223
+ # Create distribution folder
224
+ mkdir -p release/specchain-pro-v0.1.0
225
+ cp -r dist package.json LICENSE README.md release/specchain-pro-v0.1.0/
226
+
227
+ # Create archive
228
+ cd release
229
+ tar -czf specchain-pro-v0.1.0.tar.gz specchain-pro-v0.1.0
230
+ zip -r specchain-pro-v0.1.0.zip specchain-pro-v0.1.0
231
+
232
+ # Or use npm pack (creates .tgz)
233
+ cd ..
234
+ npm pack
235
+ ```
236
+
237
+ ### Users Install from Archive
238
+
239
+ ```bash
240
+ # From .tgz file
241
+ npm install -g specchain-pro-0.1.0.tgz
242
+
243
+ # From .tar.gz
244
+ tar -xzf specchain-pro-v0.1.0.tar.gz
245
+ cd specchain-pro-v0.1.0
246
+ npm install
247
+ npm link
248
+ ```
249
+
250
+ ### Share via GitHub Releases
251
+
252
+ 1. Create GitHub release
253
+ 2. Upload the .tgz or .zip file as release asset
254
+ 3. Users download and install
255
+
256
+ ### Advantages
257
+ - ✅ Simple distribution
258
+ - ✅ Works offline
259
+ - ✅ No npm registry needed
260
+ - ✅ Version control via files
261
+
262
+ ---
263
+
264
+ ## 🌐 Option 5: Self-Hosted npm Registry (Advanced)
265
+
266
+ Host your own private npm registry.
267
+
268
+ ### Using Verdaccio (Free, Open Source)
269
+
270
+ ```bash
271
+ # Install Verdaccio
272
+ npm install -g verdaccio
273
+
274
+ # Start registry
275
+ verdaccio
276
+
277
+ # Configure npm to use your registry
278
+ npm set registry http://localhost:4873
279
+
280
+ # Publish to your registry
281
+ npm publish
282
+
283
+ # Users configure their npm
284
+ npm set registry http://your-server:4873
285
+ npm install -g specchain-pro
286
+ ```
287
+
288
+ ### Advantages
289
+ - ✅ Private package hosting
290
+ - ✅ npm-like experience
291
+ - ✅ Access control
292
+ - ✅ Free and open source
293
+
294
+ ---
295
+
296
+ ## 📊 Comparison Table
297
+
298
+ | Method | Ease of Use | Distribution | Updates | Cost |
299
+ |--------|-------------|--------------|---------|------|
300
+ | **GitHub Only** | ⭐⭐⭐⭐ | Easy | Git pull | Free |
301
+ | **Local Install** | ⭐⭐⭐⭐⭐ | Manual | Manual | Free |
302
+ | **Docker** | ⭐⭐⭐ | Easy | Docker pull | Free |
303
+ | **Direct Files** | ⭐⭐⭐ | Manual | Manual | Free |
304
+ | **Self-Hosted npm** | ⭐⭐ | Easy | npm update | Free/Paid |
305
+ | **Public npm** | ⭐⭐⭐⭐⭐ | Easiest | npm update | Free |
306
+
307
+ ---
308
+
309
+ ## 🎯 Recommended Approach
310
+
311
+ ### For Personal Use
312
+ → **Local Installation** (Option 2)
313
+
314
+ ### For Team/Organization
315
+ → **GitHub Only** (Option 1) or **Docker** (Option 3)
316
+
317
+ ### For Open Source Project
318
+ → **GitHub Only** (Option 1) initially, then **npm** when mature
319
+
320
+ ### For Enterprise
321
+ → **Self-Hosted npm** (Option 5) or **Docker** (Option 3)
322
+
323
+ ---
324
+
325
+ ## 📝 Update Your README
326
+
327
+ If you skip npm, update your README.md installation section:
328
+
329
+ ```markdown
330
+ ## Installation
331
+
332
+ ### Install from GitHub
333
+
334
+ ```bash
335
+ npm install -g github:yourusername/specchain-pro
336
+ ```
337
+
338
+ ### Install from Source
339
+
340
+ ```bash
341
+ git clone https://github.com/yourusername/specchain-pro.git
342
+ cd specchain-pro
343
+ npm install
344
+ npm run build
345
+ npm link
346
+ ```
347
+
348
+ ### Using Docker
349
+
350
+ ```bash
351
+ docker pull yourusername/specchain-pro:latest
352
+ docker run yourusername/specchain-pro --help
353
+ ```
354
+
355
+ ## Usage
356
+
357
+ ```bash
358
+ spec --help
359
+ spec new "Your idea here"
360
+ ```
361
+ ```
362
+
363
+ ---
364
+
365
+ ## 🔄 Version Updates Without npm
366
+
367
+ ### GitHub Releases
368
+
369
+ ```bash
370
+ # Update version
371
+ npm version minor
372
+
373
+ # Push with tags
374
+ git push && git push --tags
375
+
376
+ # Create GitHub release with new tag
377
+ # Users update:
378
+ npm update -g github:yourusername/specchain-pro
379
+ ```
380
+
381
+ ### Docker Updates
382
+
383
+ ```bash
384
+ # Build new version
385
+ docker build -t specchain-pro:0.2.0 .
386
+ docker tag specchain-pro:0.2.0 specchain-pro:latest
387
+
388
+ # Push to Docker Hub
389
+ docker push yourusername/specchain-pro:0.2.0
390
+ docker push yourusername/specchain-pro:latest
391
+
392
+ # Users update:
393
+ docker pull yourusername/specchain-pro:latest
394
+ ```
395
+
396
+ ---
397
+
398
+ ## ✅ Quick Start (GitHub Only)
399
+
400
+ Here's the fastest way to deploy without npm:
401
+
402
+ ```bash
403
+ # 1. Build
404
+ npm run build
405
+
406
+ # 2. Initialize git
407
+ git init
408
+ git add .
409
+ git commit -m "Initial release v0.1.0"
410
+
411
+ # 3. Create GitHub repo and push
412
+ git remote add origin https://github.com/yourusername/specchain-pro.git
413
+ git push -u origin main
414
+
415
+ # 4. Create tag
416
+ git tag -a v0.1.0 -m "Release v0.1.0"
417
+ git push origin v0.1.0
418
+
419
+ # 5. Done! Users can install:
420
+ # npm install -g github:yourusername/specchain-pro
421
+ ```
422
+
423
+ ---
424
+
425
+ ## 🎉 Benefits of Skipping npm
426
+
427
+ 1. **No npm Account Needed** - Skip registration and authentication
428
+ 2. **More Control** - You control distribution completely
429
+ 3. **Privacy** - Keep code private if needed
430
+ 4. **Flexibility** - Choose your own hosting
431
+ 5. **No npm Policies** - No package name conflicts or policies
432
+
433
+ ---
434
+
435
+ ## 📞 Support
436
+
437
+ Choose the deployment method that works best for your use case. All methods are valid and production-ready!
438
+
439
+ **Recommended for most users**: GitHub Only (Option 1)
440
+
441
+ ---
442
+
443
+ **You don't need npm to deploy! 🚀**
package/ENABLE_2FA.md ADDED
@@ -0,0 +1,133 @@
1
+ # Enable 2FA for npm Publishing
2
+
3
+ npm requires Two-Factor Authentication (2FA) to publish packages. Here's how to set it up:
4
+
5
+ ## Option 1: Enable 2FA via Website (Recommended)
6
+
7
+ ### Step 1: Login to npm
8
+ Go to: https://www.npmjs.com/login
9
+
10
+ ### Step 2: Go to Account Settings
11
+ 1. Click your profile picture (top right)
12
+ 2. Click "Account"
13
+ 3. Click "Two-Factor Authentication" in the left sidebar
14
+
15
+ ### Step 3: Enable 2FA
16
+ 1. Click "Enable 2FA"
17
+ 2. Choose "Authorization and Publishing" (recommended)
18
+ 3. Scan QR code with authenticator app:
19
+ - Google Authenticator (iOS/Android)
20
+ - Microsoft Authenticator (iOS/Android)
21
+ - Authy (iOS/Android/Desktop)
22
+ 4. Enter the 6-digit code from your app
23
+ 5. Save your recovery codes in a safe place!
24
+
25
+ ### Step 4: Publish Again
26
+ ```bash
27
+ npm publish
28
+ # You'll be prompted for your 2FA code
29
+ # Enter the 6-digit code from your authenticator app
30
+ ```
31
+
32
+ ---
33
+
34
+ ## Option 2: Enable 2FA via CLI
35
+
36
+ ```bash
37
+ # Enable 2FA for authorization and publishing
38
+ npm profile enable-2fa auth-and-writes
39
+
40
+ # Follow the prompts:
41
+ # 1. Scan QR code with authenticator app
42
+ # 2. Enter 6-digit code
43
+ # 3. Save recovery codes
44
+ ```
45
+
46
+ ---
47
+
48
+ ## Option 3: Use Access Token (Alternative)
49
+
50
+ If you don't want to use 2FA, you can create an access token:
51
+
52
+ ### Step 1: Create Access Token
53
+ 1. Go to: https://www.npmjs.com/settings/YOUR_USERNAME/tokens
54
+ 2. Click "Generate New Token"
55
+ 3. Choose "Automation" token type
56
+ 4. Give it a name (e.g., "specchain-pro-publish")
57
+ 5. Click "Generate Token"
58
+ 6. Copy the token (you won't see it again!)
59
+
60
+ ### Step 2: Configure npm to Use Token
61
+ ```bash
62
+ # Set the token
63
+ npm config set //registry.npmjs.org/:_authToken YOUR_TOKEN_HERE
64
+
65
+ # Or create .npmrc file in your home directory
66
+ echo "//registry.npmjs.org/:_authToken=YOUR_TOKEN_HERE" > ~/.npmrc
67
+ ```
68
+
69
+ ### Step 3: Publish
70
+ ```bash
71
+ npm publish
72
+ # No 2FA prompt needed!
73
+ ```
74
+
75
+ ---
76
+
77
+ ## Recommended: Use 2FA (Option 1)
78
+
79
+ 2FA is more secure and is the recommended approach.
80
+
81
+ ### After Enabling 2FA
82
+
83
+ ```bash
84
+ # Publish your package
85
+ npm publish
86
+
87
+ # When prompted, enter your 2FA code
88
+ # The code changes every 30 seconds in your authenticator app
89
+ ```
90
+
91
+ ---
92
+
93
+ ## Troubleshooting
94
+
95
+ ### "Invalid OTP"
96
+ - Make sure your phone's time is synced correctly
97
+ - Wait for a new code (they expire every 30 seconds)
98
+ - Try the next code if the current one doesn't work
99
+
100
+ ### "Recovery codes not working"
101
+ - Contact npm support: https://www.npmjs.com/support
102
+
103
+ ### "Lost authenticator app"
104
+ - Use your recovery codes
105
+ - Or contact npm support
106
+
107
+ ---
108
+
109
+ ## Quick Steps Summary
110
+
111
+ 1. **Go to**: https://www.npmjs.com/settings/YOUR_USERNAME/account
112
+ 2. **Enable 2FA**: Choose "Authorization and Publishing"
113
+ 3. **Scan QR code** with authenticator app
114
+ 4. **Save recovery codes**
115
+ 5. **Try publishing again**: `npm publish`
116
+ 6. **Enter 2FA code** when prompted
117
+
118
+ ---
119
+
120
+ ## After Setup
121
+
122
+ Once 2FA is enabled, every time you publish:
123
+
124
+ ```bash
125
+ npm publish
126
+ # Enter one-time password: [6-digit code from app]
127
+ ```
128
+
129
+ ---
130
+
131
+ **Ready to enable 2FA? Go to**: https://www.npmjs.com/settings/YOUR_USERNAME/account
132
+
133
+ Then try `npm publish` again!
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 SpecChain Pro Contributors
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.