create-qa-architect 5.0.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.
Files changed (67) hide show
  1. package/.editorconfig +12 -0
  2. package/.github/CLAUDE_MD_AUTOMATION.md +248 -0
  3. package/.github/PROGRESSIVE_QUALITY_IMPLEMENTATION.md +408 -0
  4. package/.github/PROGRESSIVE_QUALITY_PROPOSAL.md +443 -0
  5. package/.github/RELEASE_CHECKLIST.md +100 -0
  6. package/.github/dependabot.yml +50 -0
  7. package/.github/git-sync.sh +48 -0
  8. package/.github/workflows/claude-md-validation.yml +82 -0
  9. package/.github/workflows/nightly-gitleaks-verification.yml +176 -0
  10. package/.github/workflows/pnpm-ci.yml.example +53 -0
  11. package/.github/workflows/python-ci.yml.example +69 -0
  12. package/.github/workflows/quality-legacy.yml.backup +165 -0
  13. package/.github/workflows/quality-progressive.yml.example +291 -0
  14. package/.github/workflows/quality.yml +436 -0
  15. package/.github/workflows/release.yml +53 -0
  16. package/.nvmrc +1 -0
  17. package/.prettierignore +14 -0
  18. package/.prettierrc +9 -0
  19. package/.stylelintrc.json +5 -0
  20. package/README.md +212 -0
  21. package/config/.lighthouserc.js +45 -0
  22. package/config/.pre-commit-config.yaml +66 -0
  23. package/config/constants.js +128 -0
  24. package/config/defaults.js +124 -0
  25. package/config/pyproject.toml +124 -0
  26. package/config/quality-config.schema.json +97 -0
  27. package/config/quality-python.yml +89 -0
  28. package/config/requirements-dev.txt +15 -0
  29. package/create-saas-monetization.js +1465 -0
  30. package/eslint.config.cjs +117 -0
  31. package/eslint.config.ts.cjs +99 -0
  32. package/legal/README.md +106 -0
  33. package/legal/copyright.md +76 -0
  34. package/legal/disclaimer.md +146 -0
  35. package/legal/privacy-policy.html +324 -0
  36. package/legal/privacy-policy.md +196 -0
  37. package/legal/terms-of-service.md +224 -0
  38. package/lib/billing-dashboard.html +645 -0
  39. package/lib/config-validator.js +163 -0
  40. package/lib/dependency-monitoring-basic.js +185 -0
  41. package/lib/dependency-monitoring-premium.js +1490 -0
  42. package/lib/error-reporter.js +444 -0
  43. package/lib/interactive/prompt.js +128 -0
  44. package/lib/interactive/questions.js +146 -0
  45. package/lib/license-validator.js +403 -0
  46. package/lib/licensing.js +989 -0
  47. package/lib/package-utils.js +187 -0
  48. package/lib/project-maturity.js +516 -0
  49. package/lib/security-enhancements.js +340 -0
  50. package/lib/setup-enhancements.js +317 -0
  51. package/lib/smart-strategy-generator.js +344 -0
  52. package/lib/telemetry.js +323 -0
  53. package/lib/template-loader.js +252 -0
  54. package/lib/typescript-config-generator.js +210 -0
  55. package/lib/ui-helpers.js +74 -0
  56. package/lib/validation/base-validator.js +174 -0
  57. package/lib/validation/cache-manager.js +158 -0
  58. package/lib/validation/config-security.js +741 -0
  59. package/lib/validation/documentation.js +326 -0
  60. package/lib/validation/index.js +186 -0
  61. package/lib/validation/validation-factory.js +153 -0
  62. package/lib/validation/workflow-validation.js +172 -0
  63. package/lib/yaml-utils.js +120 -0
  64. package/marketing/beta-user-email-campaign.md +372 -0
  65. package/marketing/landing-page.html +721 -0
  66. package/package.json +165 -0
  67. package/setup.js +2076 -0
@@ -0,0 +1,291 @@
1
+ name: Quality Checks (Progressive)
2
+
3
+ # This is an EXAMPLE of the progressive quality automation workflow.
4
+ # It demonstrates adaptive checks based on project maturity.
5
+
6
+ on:
7
+ push:
8
+ branches: [main, master, develop]
9
+ pull_request:
10
+ branches: [main, master, develop]
11
+
12
+ jobs:
13
+ # Step 1: Detect project maturity level
14
+ detect-maturity:
15
+ runs-on: ubuntu-latest
16
+ outputs:
17
+ maturity: ${{ steps.detect.outputs.maturity }}
18
+ source-count: ${{ steps.detect.outputs.source-count }}
19
+ test-count: ${{ steps.detect.outputs.test-count }}
20
+ has-deps: ${{ steps.detect.outputs.has-deps }}
21
+ has-docs: ${{ steps.detect.outputs.has-docs }}
22
+ has-css: ${{ steps.detect.outputs.has-css }}
23
+
24
+ steps:
25
+ - name: Checkout code
26
+ uses: actions/checkout@v5
27
+
28
+ - name: Setup Node.js
29
+ uses: actions/setup-node@v6
30
+ with:
31
+ node-version: '20'
32
+
33
+ - name: Detect Project Maturity
34
+ id: detect
35
+ run: |
36
+ # Use the project maturity detector
37
+ node lib/project-maturity.js --github-actions >> $GITHUB_OUTPUT
38
+
39
+ - name: Display Maturity Report
40
+ run: |
41
+ echo "๐Ÿ“Š Project Maturity Detection Results"
42
+ echo "Maturity: ${{ steps.detect.outputs.maturity }}"
43
+ echo "Source files: ${{ steps.detect.outputs.source-count }}"
44
+ echo "Test files: ${{ steps.detect.outputs.test-count }}"
45
+ echo "Has dependencies: ${{ steps.detect.outputs.has-deps }}"
46
+ echo "Has documentation: ${{ steps.detect.outputs.has-docs }}"
47
+ echo "Has CSS files: ${{ steps.detect.outputs.has-css }}"
48
+
49
+ # Step 2: Core checks - ALWAYS run (all maturity levels)
50
+ core-checks:
51
+ runs-on: ubuntu-latest
52
+ needs: detect-maturity
53
+
54
+ steps:
55
+ - name: Checkout code
56
+ uses: actions/checkout@v5
57
+
58
+ - name: Setup Node.js
59
+ uses: actions/setup-node@v6
60
+ with:
61
+ node-version: '20'
62
+ cache: 'npm'
63
+
64
+ - name: Install dependencies
65
+ run: |
66
+ if [ -f package-lock.json ]; then
67
+ npm ci
68
+ else
69
+ npm install
70
+ fi
71
+
72
+ - name: Prettier check
73
+ run: |
74
+ echo "โœจ Running Prettier formatting check (required for all projects)"
75
+ npm run format:check
76
+
77
+ # Step 3: Linting - run if source files exist (bootstrap+)
78
+ linting:
79
+ runs-on: ubuntu-latest
80
+ needs: detect-maturity
81
+ if: needs.detect-maturity.outputs.source-count > 0
82
+
83
+ steps:
84
+ - name: Checkout code
85
+ uses: actions/checkout@v5
86
+
87
+ - name: Setup Node.js
88
+ uses: actions/setup-node@v6
89
+ with:
90
+ node-version: '20'
91
+ cache: 'npm'
92
+
93
+ - name: Install dependencies
94
+ run: |
95
+ if [ -f package-lock.json ]; then
96
+ npm ci
97
+ else
98
+ npm install
99
+ fi
100
+
101
+ - name: ESLint
102
+ run: |
103
+ echo "๐Ÿ” Linting ${{ needs.detect-maturity.outputs.source-count }} source files..."
104
+ npx eslint . --max-warnings=0
105
+
106
+ - name: Stylelint
107
+ if: needs.detect-maturity.outputs.has-css == 'true'
108
+ run: |
109
+ echo "๐ŸŽจ Linting CSS files..."
110
+ npx stylelint "**/*.{css,scss,sass,less,pcss}" --allow-empty-input
111
+
112
+ # Step 4: Security checks - run if dependencies exist
113
+ security:
114
+ runs-on: ubuntu-latest
115
+ needs: detect-maturity
116
+ if: needs.detect-maturity.outputs.has-deps == 'true'
117
+
118
+ steps:
119
+ - name: Checkout code
120
+ uses: actions/checkout@v5
121
+
122
+ - name: Setup Node.js
123
+ uses: actions/setup-node@v6
124
+ with:
125
+ node-version: '20'
126
+ cache: 'npm'
127
+
128
+ - name: Install dependencies
129
+ run: |
130
+ if [ -f package-lock.json ]; then
131
+ npm ci
132
+ else
133
+ npm install
134
+ fi
135
+
136
+ - name: Verify dependency integrity
137
+ run: |
138
+ echo "๐Ÿ” Verifying dependency integrity..."
139
+ if [ -f package-lock.json ]; then
140
+ npm ci --dry-run --prefer-offline
141
+ echo "โœ… Dependency integrity verified"
142
+ else
143
+ echo "โš ๏ธ No package-lock.json found - skipping integrity verification"
144
+ fi
145
+
146
+ echo "๐Ÿ” Checking for vulnerable dependencies..."
147
+ npm audit --audit-level=moderate || true
148
+
149
+ - name: Security audit
150
+ run: npm audit --audit-level high
151
+
152
+ - name: Check for hardcoded secrets
153
+ run: |
154
+ echo "๐Ÿ” Scanning for hardcoded secrets..."
155
+ if grep -r -E "(password|secret|key|token).*[=:].*['\"][^'\"]{8,}" . \
156
+ --exclude-dir=node_modules \
157
+ --exclude-dir=.git \
158
+ --exclude-dir=.github \
159
+ --exclude-dir=tests \
160
+ --exclude="*.md" \
161
+ --exclude="package.json" || \
162
+ grep -r -E "-----BEGIN.*KEY-----" . \
163
+ --exclude-dir=node_modules \
164
+ --exclude-dir=.git \
165
+ --exclude-dir=.github \
166
+ --exclude-dir=tests; then
167
+ echo "โŒ Potential hardcoded secrets found"
168
+ exit 1
169
+ else
170
+ echo "โœ… No hardcoded secrets detected"
171
+ fi
172
+
173
+ - name: Security pattern detection
174
+ run: |
175
+ echo "๐Ÿ” Scanning for XSS vulnerability patterns..."
176
+
177
+ # Check for innerHTML with interpolation
178
+ if grep -r -E "innerHTML.*\\\$\{" . --include="*.js" --include="*.jsx" --include="*.ts" --include="*.tsx" --exclude-dir=node_modules; then
179
+ echo "โŒ Potential XSS: innerHTML with template literal interpolation found"
180
+ exit 1
181
+ fi
182
+
183
+ # Check for eval with interpolation
184
+ if grep -r -E "eval\\\(.*\\\$\{" . --include="*.js" --include="*.jsx" --include="*.ts" --include="*.tsx" --exclude-dir=node_modules; then
185
+ echo "โŒ Potential code injection: eval with interpolation found"
186
+ exit 1
187
+ fi
188
+
189
+ echo "โœ… No XSS vulnerability patterns detected"
190
+
191
+ # Step 5: Tests - run if test files exist (development+)
192
+ tests:
193
+ runs-on: ubuntu-latest
194
+ needs: detect-maturity
195
+ if: needs.detect-maturity.outputs.test-count > 0
196
+
197
+ steps:
198
+ - name: Checkout code
199
+ uses: actions/checkout@v5
200
+
201
+ - name: Setup Node.js
202
+ uses: actions/setup-node@v6
203
+ with:
204
+ node-version: '20'
205
+ cache: 'npm'
206
+
207
+ - name: Install dependencies
208
+ run: |
209
+ if [ -f package-lock.json ]; then
210
+ npm ci
211
+ else
212
+ npm install
213
+ fi
214
+
215
+ - name: Run tests
216
+ run: |
217
+ echo "๐Ÿงช Running ${{ needs.detect-maturity.outputs.test-count }} test files..."
218
+ npm test
219
+
220
+ # Step 6: Documentation - run for production-ready projects
221
+ documentation:
222
+ runs-on: ubuntu-latest
223
+ needs: detect-maturity
224
+ if: needs.detect-maturity.outputs.maturity == 'production-ready'
225
+
226
+ steps:
227
+ - name: Checkout code
228
+ uses: actions/checkout@v5
229
+
230
+ - name: Setup Node.js
231
+ uses: actions/setup-node@v6
232
+ with:
233
+ node-version: '20'
234
+ cache: 'npm'
235
+
236
+ - name: Install dependencies
237
+ run: |
238
+ if [ -f package-lock.json ]; then
239
+ npm ci
240
+ else
241
+ npm install
242
+ fi
243
+
244
+ - name: Configuration security check
245
+ run: |
246
+ echo "๐Ÿ” Running configuration security validation..."
247
+ npx create-quality-automation@latest --security-config
248
+
249
+ - name: Documentation validation
250
+ run: |
251
+ echo "๐Ÿ“– Running documentation validation..."
252
+ npx create-quality-automation@latest --validate-docs
253
+
254
+ - name: Lighthouse CI
255
+ if: hashFiles('.lighthouserc.js', '.lighthouserc.json', 'lighthouserc.js') != ''
256
+ run: |
257
+ echo "๐Ÿšข Running Lighthouse CI..."
258
+ npx lhci autorun
259
+ continue-on-error: true
260
+
261
+ # Step 7: Summary - report what checks ran
262
+ summary:
263
+ runs-on: ubuntu-latest
264
+ needs:
265
+ - detect-maturity
266
+ - core-checks
267
+ - linting
268
+ - security
269
+ - tests
270
+ - documentation
271
+ if: always()
272
+
273
+ steps:
274
+ - name: Generate Check Summary
275
+ run: |
276
+ echo "## Quality Checks Summary ๐Ÿ“Š" >> $GITHUB_STEP_SUMMARY
277
+ echo "" >> $GITHUB_STEP_SUMMARY
278
+ echo "**Maturity Level:** ${{ needs.detect-maturity.outputs.maturity }}" >> $GITHUB_STEP_SUMMARY
279
+ echo "" >> $GITHUB_STEP_SUMMARY
280
+ echo "### Project Statistics" >> $GITHUB_STEP_SUMMARY
281
+ echo "- Source files: ${{ needs.detect-maturity.outputs.source-count }}" >> $GITHUB_STEP_SUMMARY
282
+ echo "- Test files: ${{ needs.detect-maturity.outputs.test-count }}" >> $GITHUB_STEP_SUMMARY
283
+ echo "- Has dependencies: ${{ needs.detect-maturity.outputs.has-deps }}" >> $GITHUB_STEP_SUMMARY
284
+ echo "- Has documentation: ${{ needs.detect-maturity.outputs.has-docs }}" >> $GITHUB_STEP_SUMMARY
285
+ echo "" >> $GITHUB_STEP_SUMMARY
286
+ echo "### Checks Executed" >> $GITHUB_STEP_SUMMARY
287
+ echo "- โœ… Core checks: Always run" >> $GITHUB_STEP_SUMMARY
288
+ echo "- ${{ needs.detect-maturity.outputs.source-count > 0 && 'โœ…' || 'โญ๏ธ' }} Linting: ${{ needs.detect-maturity.outputs.source-count > 0 && 'Enabled' || 'Skipped (no source files)' }}" >> $GITHUB_STEP_SUMMARY
289
+ echo "- ${{ needs.detect-maturity.outputs.has-deps == 'true' && 'โœ…' || 'โญ๏ธ' }} Security: ${{ needs.detect-maturity.outputs.has-deps == 'true' && 'Enabled' || 'Skipped (no dependencies)' }}" >> $GITHUB_STEP_SUMMARY
290
+ echo "- ${{ needs.detect-maturity.outputs.test-count > 0 && 'โœ…' || 'โญ๏ธ' }} Tests: ${{ needs.detect-maturity.outputs.test-count > 0 && 'Enabled' || 'Skipped (no test files)' }}" >> $GITHUB_STEP_SUMMARY
291
+ echo "- ${{ needs.detect-maturity.outputs.maturity == 'production-ready' && 'โœ…' || 'โญ๏ธ' }} Documentation: ${{ needs.detect-maturity.outputs.maturity == 'production-ready' && 'Enabled' || 'Skipped (not production-ready)' }}" >> $GITHUB_STEP_SUMMARY