@mytechtoday/augment-extensions 1.4.0 → 1.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/augment-extensions/coding-standards/c/CHANGELOG.md +55 -0
- package/augment-extensions/coding-standards/c/LICENSE +22 -0
- package/augment-extensions/coding-standards/c/README.md +167 -0
- package/augment-extensions/coding-standards/c/config/defaults.json +26 -0
- package/augment-extensions/coding-standards/c/config/examples/embedded.yaml +25 -0
- package/augment-extensions/coding-standards/c/config/examples/systems.json +31 -0
- package/augment-extensions/coding-standards/c/config/schema.json +244 -0
- package/augment-extensions/coding-standards/c/docs/API.md +613 -0
- package/augment-extensions/coding-standards/c/docs/CONFIGURATION.md +259 -0
- package/augment-extensions/coding-standards/c/docs/USER_GUIDE.md +567 -0
- package/augment-extensions/coding-standards/c/examples/drivers/Makefile +33 -0
- package/augment-extensions/coding-standards/c/examples/drivers/README.md +192 -0
- package/augment-extensions/coding-standards/c/examples/drivers/dma-example.c +224 -0
- package/augment-extensions/coding-standards/c/examples/drivers/example.dts +64 -0
- package/augment-extensions/coding-standards/c/examples/drivers/platform-driver.c +174 -0
- package/augment-extensions/coding-standards/c/examples/embedded/README.md +167 -0
- package/augment-extensions/coding-standards/c/examples/embedded/gpio-control.c +172 -0
- package/augment-extensions/coding-standards/c/examples/embedded/timer-isr.c +198 -0
- package/augment-extensions/coding-standards/c/examples/embedded/uart-communication.c +212 -0
- package/augment-extensions/coding-standards/c/examples/kernel/Makefile +82 -0
- package/augment-extensions/coding-standards/c/examples/kernel/README.md +168 -0
- package/augment-extensions/coding-standards/c/examples/kernel/char-device.c +198 -0
- package/augment-extensions/coding-standards/c/examples/kernel/proc-file.c +131 -0
- package/augment-extensions/coding-standards/c/examples/kernel/simple-module.c +111 -0
- package/augment-extensions/coding-standards/c/examples/legacy/Makefile +62 -0
- package/augment-extensions/coding-standards/c/examples/legacy/README.md +255 -0
- package/augment-extensions/coding-standards/c/examples/legacy/c89-to-c11-migration.c +268 -0
- package/augment-extensions/coding-standards/c/examples/legacy/compatibility-layer.c +239 -0
- package/augment-extensions/coding-standards/c/examples/networking/Makefile +35 -0
- package/augment-extensions/coding-standards/c/examples/networking/README.md +207 -0
- package/augment-extensions/coding-standards/c/examples/networking/protocol-parser.c +270 -0
- package/augment-extensions/coding-standards/c/examples/networking/tcp-server.c +197 -0
- package/augment-extensions/coding-standards/c/examples/networking/udp-multicast.c +220 -0
- package/augment-extensions/coding-standards/c/examples/realtime/Makefile +53 -0
- package/augment-extensions/coding-standards/c/examples/realtime/README.md +199 -0
- package/augment-extensions/coding-standards/c/examples/realtime/deadline-monitoring.c +260 -0
- package/augment-extensions/coding-standards/c/examples/realtime/priority-scheduling.c +258 -0
- package/augment-extensions/coding-standards/c/examples/systems/Makefile +34 -0
- package/augment-extensions/coding-standards/c/examples/systems/README.md +123 -0
- package/augment-extensions/coding-standards/c/examples/systems/ipc-pipes.c +181 -0
- package/augment-extensions/coding-standards/c/examples/systems/process-management.c +153 -0
- package/augment-extensions/coding-standards/c/examples/systems/signal-handling.c +162 -0
- package/augment-extensions/coding-standards/c/module.json +149 -0
- package/augment-extensions/coding-standards/c/rules/categories/drivers.md +635 -0
- package/augment-extensions/coding-standards/c/rules/categories/embedded.md +510 -0
- package/augment-extensions/coding-standards/c/rules/categories/kernel.md +653 -0
- package/augment-extensions/coding-standards/c/rules/categories/legacy.md +526 -0
- package/augment-extensions/coding-standards/c/rules/categories/networking.md +735 -0
- package/augment-extensions/coding-standards/c/rules/categories/realtime.md +631 -0
- package/augment-extensions/coding-standards/c/rules/categories/systems.md +586 -0
- package/augment-extensions/coding-standards/c/rules/universal/const-correctness.md +275 -0
- package/augment-extensions/coding-standards/c/rules/universal/documentation.md +251 -0
- package/augment-extensions/coding-standards/c/rules/universal/error-handling.md +250 -0
- package/augment-extensions/coding-standards/c/rules/universal/header-guards.md +254 -0
- package/augment-extensions/coding-standards/c/rules/universal/memory-safety.md +233 -0
- package/augment-extensions/coding-standards/c/rules/universal/naming.md +146 -0
- package/augment-extensions/coding-standards/c/src/conflict-detector.ts +461 -0
- package/augment-extensions/coding-standards/c/src/prompt-generator.ts +307 -0
- package/augment-extensions/coding-standards/c/src/rule-evaluator.ts +307 -0
- package/augment-extensions/coding-standards/c/src/rule-override.ts +427 -0
- package/augment-extensions/coding-standards/c/src/template-engine.ts +217 -0
- package/augment-extensions/coding-standards/c/templates/prompts/drivers.txt +191 -0
- package/augment-extensions/coding-standards/c/templates/prompts/embedded.txt +164 -0
- package/augment-extensions/coding-standards/c/templates/prompts/kernel.txt +175 -0
- package/augment-extensions/coding-standards/c/templates/prompts/legacy.txt +280 -0
- package/augment-extensions/coding-standards/c/templates/prompts/networking.txt +259 -0
- package/augment-extensions/coding-standards/c/templates/prompts/realtime.txt +219 -0
- package/augment-extensions/coding-standards/c/templates/prompts/systems.txt +147 -0
- package/augment-extensions/coding-standards/c/tests/integration/category-specific.test.ts +356 -0
- package/augment-extensions/coding-standards/c/tests/integration/end-to-end-workflow.test.ts +377 -0
- package/augment-extensions/coding-standards/c/tests/performance/benchmarks.test.ts +407 -0
- package/augment-extensions/coding-standards/c/tests/unit/config-manager.test.ts +345 -0
- package/augment-extensions/coding-standards/c/tests/unit/conflict-detector.test.ts +294 -0
- package/augment-extensions/coding-standards/c/tests/unit/prompt-generator.test.ts +174 -0
- package/augment-extensions/coding-standards/c/tests/unit/registry.test.ts +313 -0
- package/augment-extensions/coding-standards/c/tests/unit/rule-evaluator.test.ts +318 -0
- package/augment-extensions/coding-standards/c/tests/unit/rule-override.test.ts +326 -0
- package/augment-extensions/coding-standards/c/tests/unit/template-engine.test.ts +314 -0
- package/augment-extensions/coding-standards/go/CHARACTER-COUNT-REPORT.md +135 -0
- package/augment-extensions/coding-standards/go/PHASE1-COMPLETION.md +146 -0
- package/augment-extensions/coding-standards/go/PHASE4-COMPLETION.md +184 -0
- package/augment-extensions/coding-standards/go/README.md +200 -0
- package/augment-extensions/coding-standards/go/VALIDATION-CHECKLIST.md +154 -0
- package/augment-extensions/coding-standards/go/config/examples/example-cli.json +15 -0
- package/augment-extensions/coding-standards/go/config/examples/example-microservices.json +21 -0
- package/augment-extensions/coding-standards/go/config/examples/example-multi-category.yaml +24 -0
- package/augment-extensions/coding-standards/go/config/examples/example-web.json +15 -0
- package/augment-extensions/coding-standards/go/config/schema.json +110 -0
- package/augment-extensions/coding-standards/go/docs/CATEGORIES.md +221 -0
- package/augment-extensions/coding-standards/go/docs/CONFIGURATION.md +198 -0
- package/augment-extensions/coding-standards/go/docs/TROUBLESHOOTING.md +285 -0
- package/augment-extensions/coding-standards/go/examples/cli/cobra-app.go +287 -0
- package/augment-extensions/coding-standards/go/examples/cloud-native-app.go +217 -0
- package/augment-extensions/coding-standards/go/examples/devops-tool.go +250 -0
- package/augment-extensions/coding-standards/go/examples/distributed-system.go +247 -0
- package/augment-extensions/coding-standards/go/examples/microservices/grpc-service.go +253 -0
- package/augment-extensions/coding-standards/go/examples/rest-api.go +270 -0
- package/augment-extensions/coding-standards/go/examples/web/http-server.go +224 -0
- package/augment-extensions/coding-standards/go/module.json +139 -0
- package/augment-extensions/coding-standards/go/rules/categories/api-development/api-versioning.md +149 -0
- package/augment-extensions/coding-standards/go/rules/categories/api-development/rate-limiting.md +209 -0
- package/augment-extensions/coding-standards/go/rules/categories/api-development/rest-api-design.md +183 -0
- package/augment-extensions/coding-standards/go/rules/categories/cloud-native/cloud-config.md +193 -0
- package/augment-extensions/coding-standards/go/rules/categories/cloud-native/health-checks.md +231 -0
- package/augment-extensions/coding-standards/go/rules/categories/cloud-native/kubernetes.md +180 -0
- package/augment-extensions/coding-standards/go/rules/categories/devops-tooling/automation.md +179 -0
- package/augment-extensions/coding-standards/go/rules/categories/devops-tooling/ci-cd-integration.md +147 -0
- package/augment-extensions/coding-standards/go/rules/categories/devops-tooling/infrastructure-as-code.md +231 -0
- package/augment-extensions/coding-standards/go/rules/categories/distributed-systems/caching.md +150 -0
- package/augment-extensions/coding-standards/go/rules/categories/distributed-systems/consensus.md +187 -0
- package/augment-extensions/coding-standards/go/rules/categories/distributed-systems/event-sourcing.md +246 -0
- package/augment-extensions/coding-standards/go/rules/cli/command-parsing.md +264 -0
- package/augment-extensions/coding-standards/go/rules/cli/configuration.md +268 -0
- package/augment-extensions/coding-standards/go/rules/cli/cross-platform.md +324 -0
- package/augment-extensions/coding-standards/go/rules/microservices/distributed-tracing.md +253 -0
- package/augment-extensions/coding-standards/go/rules/microservices/grpc.md +257 -0
- package/augment-extensions/coding-standards/go/rules/microservices/metrics.md +278 -0
- package/augment-extensions/coding-standards/go/rules/microservices/service-discovery.md +249 -0
- package/augment-extensions/coding-standards/go/rules/universal/code-organization.md +221 -0
- package/augment-extensions/coding-standards/go/rules/universal/documentation.md +269 -0
- package/augment-extensions/coding-standards/go/rules/universal/performance.md +323 -0
- package/augment-extensions/coding-standards/go/rules/universal/testing.md +162 -0
- package/augment-extensions/coding-standards/go/rules/web/graceful-shutdown.md +249 -0
- package/augment-extensions/coding-standards/go/rules/web/http-handlers.md +164 -0
- package/augment-extensions/coding-standards/go/rules/web/middleware.md +234 -0
- package/augment-extensions/coding-standards/go/rules/web/routing.md +251 -0
- package/augment-extensions/coding-standards/go/templates/prompts/api.md +160 -0
- package/augment-extensions/coding-standards/go/templates/prompts/cli.md +225 -0
- package/augment-extensions/coding-standards/go/templates/prompts/cloud-native.md +121 -0
- package/augment-extensions/coding-standards/go/templates/prompts/devops.md +146 -0
- package/augment-extensions/coding-standards/go/templates/prompts/distributed.md +133 -0
- package/augment-extensions/coding-standards/go/templates/prompts/microservices.md +225 -0
- package/augment-extensions/coding-standards/go/templates/prompts/web.md +181 -0
- package/augment-extensions/coding-standards/go/tests/integration/module-integration.test.ts +164 -0
- package/augment-extensions/coding-standards/go/tests/unit/category-selection.test.ts +147 -0
- package/augment-extensions/coding-standards/go/tests/unit/module-structure.test.ts +154 -0
- package/augment-extensions/coding-standards/go/tests/validate-character-count.ps1 +13 -0
- package/augment-extensions/coding-standards/go/tests/validate-examples.ps1 +148 -0
- package/augment-extensions/coding-standards/go/tests/validate-examples.sh +135 -0
- package/cli/dist/analysis/ast-parser.d.ts +47 -0
- package/cli/dist/analysis/ast-parser.d.ts.map +1 -0
- package/cli/dist/analysis/ast-parser.js +161 -0
- package/cli/dist/analysis/ast-parser.js.map +1 -0
- package/cli/dist/analysis/complexity-analyzer.d.ts +27 -0
- package/cli/dist/analysis/complexity-analyzer.d.ts.map +1 -0
- package/cli/dist/analysis/complexity-analyzer.js +189 -0
- package/cli/dist/analysis/complexity-analyzer.js.map +1 -0
- package/cli/dist/analysis/dependency-analyzer.d.ts +23 -0
- package/cli/dist/analysis/dependency-analyzer.d.ts.map +1 -0
- package/cli/dist/analysis/dependency-analyzer.js +237 -0
- package/cli/dist/analysis/dependency-analyzer.js.map +1 -0
- package/cli/dist/analysis/index.d.ts +9 -0
- package/cli/dist/analysis/index.d.ts.map +1 -0
- package/cli/dist/analysis/index.js +25 -0
- package/cli/dist/analysis/index.js.map +1 -0
- package/cli/dist/analysis/security-scanner.d.ts +11 -0
- package/cli/dist/analysis/security-scanner.d.ts.map +1 -0
- package/cli/dist/analysis/security-scanner.js +294 -0
- package/cli/dist/analysis/security-scanner.js.map +1 -0
- package/cli/dist/analysis/types.d.ts +151 -0
- package/cli/dist/analysis/types.d.ts.map +1 -0
- package/cli/dist/analysis/types.js +6 -0
- package/cli/dist/analysis/types.js.map +1 -0
- package/cli/dist/cli.js +24 -0
- package/cli/dist/cli.js.map +1 -1
- package/cli/dist/commands/code-analysis.d.ts +11 -0
- package/cli/dist/commands/code-analysis.d.ts.map +1 -0
- package/cli/dist/commands/code-analysis.js +412 -0
- package/cli/dist/commands/code-analysis.js.map +1 -0
- package/modules.md +99 -3
- package/package.json +14 -2
- package/cli/dist/commands/agent.d.ts +0 -37
- package/cli/dist/commands/agent.d.ts.map +0 -1
- package/cli/dist/commands/agent.js +0 -222
- package/cli/dist/commands/agent.js.map +0 -1
- package/cli/dist/commands/beads.d.ts +0 -64
- package/cli/dist/commands/beads.d.ts.map +0 -1
- package/cli/dist/commands/beads.js +0 -377
- package/cli/dist/commands/beads.js.map +0 -1
- package/cli/dist/commands/change.d.ts +0 -54
- package/cli/dist/commands/change.d.ts.map +0 -1
- package/cli/dist/commands/change.js +0 -243
- package/cli/dist/commands/change.js.map +0 -1
- package/cli/dist/commands/clean.d.ts +0 -15
- package/cli/dist/commands/clean.d.ts.map +0 -1
- package/cli/dist/commands/clean.js +0 -63
- package/cli/dist/commands/clean.js.map +0 -1
- package/cli/dist/commands/clone.d.ts +0 -15
- package/cli/dist/commands/clone.d.ts.map +0 -1
- package/cli/dist/commands/clone.js +0 -49
- package/cli/dist/commands/clone.js.map +0 -1
- package/cli/dist/commands/config.d.ts +0 -33
- package/cli/dist/commands/config.d.ts.map +0 -1
- package/cli/dist/commands/config.js +0 -166
- package/cli/dist/commands/config.js.map +0 -1
- package/cli/dist/commands/context.d.ts +0 -38
- package/cli/dist/commands/context.d.ts.map +0 -1
- package/cli/dist/commands/context.js +0 -205
- package/cli/dist/commands/context.js.map +0 -1
- package/cli/dist/commands/create.d.ts +0 -18
- package/cli/dist/commands/create.d.ts.map +0 -1
- package/cli/dist/commands/create.js +0 -178
- package/cli/dist/commands/create.js.map +0 -1
- package/cli/dist/commands/diff.d.ts +0 -19
- package/cli/dist/commands/diff.d.ts.map +0 -1
- package/cli/dist/commands/diff.js +0 -104
- package/cli/dist/commands/diff.js.map +0 -1
- package/cli/dist/commands/doctor.d.ts +0 -14
- package/cli/dist/commands/doctor.d.ts.map +0 -1
- package/cli/dist/commands/doctor.js +0 -62
- package/cli/dist/commands/doctor.js.map +0 -1
- package/cli/dist/commands/export.d.ts +0 -28
- package/cli/dist/commands/export.d.ts.map +0 -1
- package/cli/dist/commands/export.js +0 -135
- package/cli/dist/commands/export.js.map +0 -1
- package/cli/dist/commands/import.d.ts +0 -23
- package/cli/dist/commands/import.d.ts.map +0 -1
- package/cli/dist/commands/import.js +0 -118
- package/cli/dist/commands/import.js.map +0 -1
- package/cli/dist/commands/prompt.d.ts +0 -45
- package/cli/dist/commands/prompt.d.ts.map +0 -1
- package/cli/dist/commands/prompt.js +0 -223
- package/cli/dist/commands/prompt.js.map +0 -1
- package/cli/dist/commands/spec.d.ts +0 -57
- package/cli/dist/commands/spec.d.ts.map +0 -1
- package/cli/dist/commands/spec.js +0 -279
- package/cli/dist/commands/spec.js.map +0 -1
- package/cli/dist/commands/stats.d.ts +0 -18
- package/cli/dist/commands/stats.d.ts.map +0 -1
- package/cli/dist/commands/stats.js +0 -85
- package/cli/dist/commands/stats.js.map +0 -1
- package/cli/dist/commands/task.d.ts +0 -65
- package/cli/dist/commands/task.d.ts.map +0 -1
- package/cli/dist/commands/task.js +0 -282
- package/cli/dist/commands/task.js.map +0 -1
- package/cli/dist/commands/template.d.ts +0 -17
- package/cli/dist/commands/template.d.ts.map +0 -1
- package/cli/dist/commands/template.js +0 -55
- package/cli/dist/commands/template.js.map +0 -1
- package/cli/dist/utils/agent-config.d.ts +0 -129
- package/cli/dist/utils/agent-config.d.ts.map +0 -1
- package/cli/dist/utils/agent-config.js +0 -297
- package/cli/dist/utils/agent-config.js.map +0 -1
- package/cli/dist/utils/beads-graph.d.ts +0 -17
- package/cli/dist/utils/beads-graph.d.ts.map +0 -1
- package/cli/dist/utils/beads-graph.js +0 -150
- package/cli/dist/utils/beads-graph.js.map +0 -1
- package/cli/dist/utils/beads-integration.d.ts +0 -112
- package/cli/dist/utils/beads-integration.d.ts.map +0 -1
- package/cli/dist/utils/beads-integration.js +0 -312
- package/cli/dist/utils/beads-integration.js.map +0 -1
- package/cli/dist/utils/beads-reporter.d.ts +0 -17
- package/cli/dist/utils/beads-reporter.d.ts.map +0 -1
- package/cli/dist/utils/beads-reporter.js +0 -160
- package/cli/dist/utils/beads-reporter.js.map +0 -1
- package/cli/dist/utils/cache-manager.d.ts +0 -55
- package/cli/dist/utils/cache-manager.d.ts.map +0 -1
- package/cli/dist/utils/cache-manager.js +0 -150
- package/cli/dist/utils/cache-manager.js.map +0 -1
- package/cli/dist/utils/change-manager.d.ts +0 -70
- package/cli/dist/utils/change-manager.d.ts.map +0 -1
- package/cli/dist/utils/change-manager.js +0 -412
- package/cli/dist/utils/change-manager.js.map +0 -1
- package/cli/dist/utils/config-manager-enhanced.d.ts +0 -66
- package/cli/dist/utils/config-manager-enhanced.d.ts.map +0 -1
- package/cli/dist/utils/config-manager-enhanced.js +0 -77
- package/cli/dist/utils/config-manager-enhanced.js.map +0 -1
- package/cli/dist/utils/context-manager.d.ts +0 -96
- package/cli/dist/utils/context-manager.d.ts.map +0 -1
- package/cli/dist/utils/context-manager.js +0 -258
- package/cli/dist/utils/context-manager.js.map +0 -1
- package/cli/dist/utils/diff-engine.d.ts +0 -78
- package/cli/dist/utils/diff-engine.d.ts.map +0 -1
- package/cli/dist/utils/diff-engine.js +0 -233
- package/cli/dist/utils/diff-engine.js.map +0 -1
- package/cli/dist/utils/export-system.d.ts +0 -101
- package/cli/dist/utils/export-system.d.ts.map +0 -1
- package/cli/dist/utils/export-system.js +0 -289
- package/cli/dist/utils/export-system.js.map +0 -1
- package/cli/dist/utils/health-checker.d.ts +0 -66
- package/cli/dist/utils/health-checker.d.ts.map +0 -1
- package/cli/dist/utils/health-checker.js +0 -285
- package/cli/dist/utils/health-checker.js.map +0 -1
- package/cli/dist/utils/import-system.d.ts +0 -74
- package/cli/dist/utils/import-system.d.ts.map +0 -1
- package/cli/dist/utils/import-system.js +0 -317
- package/cli/dist/utils/import-system.js.map +0 -1
- package/cli/dist/utils/module-cloner.d.ts +0 -40
- package/cli/dist/utils/module-cloner.d.ts.map +0 -1
- package/cli/dist/utils/module-cloner.js +0 -136
- package/cli/dist/utils/module-cloner.js.map +0 -1
- package/cli/dist/utils/prompt-manager.d.ts +0 -90
- package/cli/dist/utils/prompt-manager.d.ts.map +0 -1
- package/cli/dist/utils/prompt-manager.js +0 -302
- package/cli/dist/utils/prompt-manager.js.map +0 -1
- package/cli/dist/utils/spec-manager.d.ts +0 -65
- package/cli/dist/utils/spec-manager.d.ts.map +0 -1
- package/cli/dist/utils/spec-manager.js +0 -329
- package/cli/dist/utils/spec-manager.js.map +0 -1
- package/cli/dist/utils/stats-collector.d.ts +0 -74
- package/cli/dist/utils/stats-collector.d.ts.map +0 -1
- package/cli/dist/utils/stats-collector.js +0 -164
- package/cli/dist/utils/stats-collector.js.map +0 -1
- package/cli/dist/utils/template-engine.d.ts +0 -47
- package/cli/dist/utils/template-engine.d.ts.map +0 -1
- package/cli/dist/utils/template-engine.js +0 -204
- package/cli/dist/utils/template-engine.js.map +0 -1
|
@@ -1,233 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Diff Engine for Augment Extensions
|
|
4
|
-
* Compares modules and versions
|
|
5
|
-
*/
|
|
6
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
-
if (k2 === undefined) k2 = k;
|
|
8
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
9
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
10
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
11
|
-
}
|
|
12
|
-
Object.defineProperty(o, k2, desc);
|
|
13
|
-
}) : (function(o, m, k, k2) {
|
|
14
|
-
if (k2 === undefined) k2 = k;
|
|
15
|
-
o[k2] = m[k];
|
|
16
|
-
}));
|
|
17
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
18
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
19
|
-
}) : function(o, v) {
|
|
20
|
-
o["default"] = v;
|
|
21
|
-
});
|
|
22
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
23
|
-
var ownKeys = function(o) {
|
|
24
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
25
|
-
var ar = [];
|
|
26
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
27
|
-
return ar;
|
|
28
|
-
};
|
|
29
|
-
return ownKeys(o);
|
|
30
|
-
};
|
|
31
|
-
return function (mod) {
|
|
32
|
-
if (mod && mod.__esModule) return mod;
|
|
33
|
-
var result = {};
|
|
34
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
35
|
-
__setModuleDefault(result, mod);
|
|
36
|
-
return result;
|
|
37
|
-
};
|
|
38
|
-
})();
|
|
39
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
40
|
-
exports.DiffEngine = void 0;
|
|
41
|
-
const fs = __importStar(require("fs"));
|
|
42
|
-
const path = __importStar(require("path"));
|
|
43
|
-
const module_system_1 = require("./module-system");
|
|
44
|
-
/**
|
|
45
|
-
* Diff Engine class
|
|
46
|
-
*/
|
|
47
|
-
class DiffEngine {
|
|
48
|
-
/**
|
|
49
|
-
* Compare two modules
|
|
50
|
-
*/
|
|
51
|
-
async compareModules(module1Name, module2Name, options = {}) {
|
|
52
|
-
try {
|
|
53
|
-
const mod1 = await (0, module_system_1.loadModule)(module1Name);
|
|
54
|
-
const mod2 = await (0, module_system_1.loadModule)(module2Name);
|
|
55
|
-
if (!mod1 || !mod2) {
|
|
56
|
-
return {
|
|
57
|
-
success: false,
|
|
58
|
-
differences: [],
|
|
59
|
-
summary: this.createEmptySummary(),
|
|
60
|
-
errors: [
|
|
61
|
-
!mod1 ? `Module not found: ${module1Name}` : '',
|
|
62
|
-
!mod2 ? `Module not found: ${module2Name}` : ''
|
|
63
|
-
].filter(Boolean)
|
|
64
|
-
};
|
|
65
|
-
}
|
|
66
|
-
const differences = this.computeDifferences(mod1, mod2, options);
|
|
67
|
-
const summary = this.computeSummary(differences);
|
|
68
|
-
return {
|
|
69
|
-
success: true,
|
|
70
|
-
differences: options.onlyDifferences
|
|
71
|
-
? differences.filter(d => d.status !== 'unchanged')
|
|
72
|
-
: differences,
|
|
73
|
-
summary
|
|
74
|
-
};
|
|
75
|
-
}
|
|
76
|
-
catch (error) {
|
|
77
|
-
return {
|
|
78
|
-
success: false,
|
|
79
|
-
differences: [],
|
|
80
|
-
summary: this.createEmptySummary(),
|
|
81
|
-
errors: [error instanceof Error ? error.message : String(error)]
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
|
-
* Compare module versions
|
|
87
|
-
*/
|
|
88
|
-
async compareVersions(moduleName, version1, version2, options = {}) {
|
|
89
|
-
// For now, this is a placeholder
|
|
90
|
-
// In a real implementation, you'd load different versions from git or version history
|
|
91
|
-
return {
|
|
92
|
-
success: false,
|
|
93
|
-
differences: [],
|
|
94
|
-
summary: this.createEmptySummary(),
|
|
95
|
-
errors: ['Version comparison not yet implemented']
|
|
96
|
-
};
|
|
97
|
-
}
|
|
98
|
-
/**
|
|
99
|
-
* Compute differences between two modules
|
|
100
|
-
*/
|
|
101
|
-
computeDifferences(mod1, mod2, options) {
|
|
102
|
-
const differences = [];
|
|
103
|
-
// Compare metadata
|
|
104
|
-
differences.push(...this.compareMetadata(mod1.metadata, mod2.metadata));
|
|
105
|
-
// Compare rules
|
|
106
|
-
differences.push(...this.compareFiles(mod1.rules, mod2.rules, 'rules', options.includeContent));
|
|
107
|
-
// Compare examples
|
|
108
|
-
differences.push(...this.compareFiles(mod1.examples, mod2.examples, 'examples', options.includeContent));
|
|
109
|
-
return differences;
|
|
110
|
-
}
|
|
111
|
-
/**
|
|
112
|
-
* Compare metadata objects
|
|
113
|
-
*/
|
|
114
|
-
compareMetadata(meta1, meta2) {
|
|
115
|
-
const differences = [];
|
|
116
|
-
const allKeys = new Set([...Object.keys(meta1), ...Object.keys(meta2)]);
|
|
117
|
-
for (const key of allKeys) {
|
|
118
|
-
const val1 = meta1[key];
|
|
119
|
-
const val2 = meta2[key];
|
|
120
|
-
if (val1 === undefined && val2 !== undefined) {
|
|
121
|
-
differences.push({
|
|
122
|
-
type: 'metadata',
|
|
123
|
-
field: key,
|
|
124
|
-
newValue: val2,
|
|
125
|
-
status: 'added'
|
|
126
|
-
});
|
|
127
|
-
}
|
|
128
|
-
else if (val1 !== undefined && val2 === undefined) {
|
|
129
|
-
differences.push({
|
|
130
|
-
type: 'metadata',
|
|
131
|
-
field: key,
|
|
132
|
-
oldValue: val1,
|
|
133
|
-
status: 'removed'
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
else if (JSON.stringify(val1) !== JSON.stringify(val2)) {
|
|
137
|
-
differences.push({
|
|
138
|
-
type: 'metadata',
|
|
139
|
-
field: key,
|
|
140
|
-
oldValue: val1,
|
|
141
|
-
newValue: val2,
|
|
142
|
-
status: 'modified'
|
|
143
|
-
});
|
|
144
|
-
}
|
|
145
|
-
else {
|
|
146
|
-
differences.push({
|
|
147
|
-
type: 'metadata',
|
|
148
|
-
field: key,
|
|
149
|
-
oldValue: val1,
|
|
150
|
-
newValue: val2,
|
|
151
|
-
status: 'unchanged'
|
|
152
|
-
});
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
return differences;
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* Compare file lists
|
|
159
|
-
*/
|
|
160
|
-
compareFiles(files1, files2, type, includeContent = false) {
|
|
161
|
-
const differences = [];
|
|
162
|
-
const names1 = files1.map(f => path.basename(f));
|
|
163
|
-
const names2 = files2.map(f => path.basename(f));
|
|
164
|
-
const allNames = new Set([...names1, ...names2]);
|
|
165
|
-
for (const name of allNames) {
|
|
166
|
-
const file1 = files1.find(f => path.basename(f) === name);
|
|
167
|
-
const file2 = files2.find(f => path.basename(f) === name);
|
|
168
|
-
if (!file1 && file2) {
|
|
169
|
-
differences.push({
|
|
170
|
-
type,
|
|
171
|
-
field: name,
|
|
172
|
-
newValue: includeContent ? fs.readFileSync(file2, 'utf-8') : name,
|
|
173
|
-
status: 'added'
|
|
174
|
-
});
|
|
175
|
-
}
|
|
176
|
-
else if (file1 && !file2) {
|
|
177
|
-
differences.push({
|
|
178
|
-
type,
|
|
179
|
-
field: name,
|
|
180
|
-
oldValue: includeContent ? fs.readFileSync(file1, 'utf-8') : name,
|
|
181
|
-
status: 'removed'
|
|
182
|
-
});
|
|
183
|
-
}
|
|
184
|
-
else if (file1 && file2) {
|
|
185
|
-
const content1 = fs.readFileSync(file1, 'utf-8');
|
|
186
|
-
const content2 = fs.readFileSync(file2, 'utf-8');
|
|
187
|
-
if (content1 !== content2) {
|
|
188
|
-
differences.push({
|
|
189
|
-
type,
|
|
190
|
-
field: name,
|
|
191
|
-
oldValue: includeContent ? content1 : name,
|
|
192
|
-
newValue: includeContent ? content2 : name,
|
|
193
|
-
status: 'modified'
|
|
194
|
-
});
|
|
195
|
-
}
|
|
196
|
-
else {
|
|
197
|
-
differences.push({
|
|
198
|
-
type,
|
|
199
|
-
field: name,
|
|
200
|
-
status: 'unchanged'
|
|
201
|
-
});
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
return differences;
|
|
206
|
-
}
|
|
207
|
-
/**
|
|
208
|
-
* Compute summary statistics
|
|
209
|
-
*/
|
|
210
|
-
computeSummary(differences) {
|
|
211
|
-
return {
|
|
212
|
-
totalDifferences: differences.length,
|
|
213
|
-
added: differences.filter(d => d.status === 'added').length,
|
|
214
|
-
removed: differences.filter(d => d.status === 'removed').length,
|
|
215
|
-
modified: differences.filter(d => d.status === 'modified').length,
|
|
216
|
-
unchanged: differences.filter(d => d.status === 'unchanged').length
|
|
217
|
-
};
|
|
218
|
-
}
|
|
219
|
-
/**
|
|
220
|
-
* Create empty summary
|
|
221
|
-
*/
|
|
222
|
-
createEmptySummary() {
|
|
223
|
-
return {
|
|
224
|
-
totalDifferences: 0,
|
|
225
|
-
added: 0,
|
|
226
|
-
removed: 0,
|
|
227
|
-
modified: 0,
|
|
228
|
-
unchanged: 0
|
|
229
|
-
};
|
|
230
|
-
}
|
|
231
|
-
}
|
|
232
|
-
exports.DiffEngine = DiffEngine;
|
|
233
|
-
//# sourceMappingURL=diff-engine.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"diff-engine.js","sourceRoot":"","sources":["../../src/utils/diff-engine.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2CAA6B;AAC7B,mDAAqD;AA8CrD;;GAEG;AACH,MAAa,UAAU;IACrB;;OAEG;IACH,KAAK,CAAC,cAAc,CAClB,WAAmB,EACnB,WAAmB,EACnB,UAAuB,EAAE;QAEzB,IAAI,CAAC;YACH,MAAM,IAAI,GAAG,MAAM,IAAA,0BAAU,EAAC,WAAW,CAAC,CAAC;YAC3C,MAAM,IAAI,GAAG,MAAM,IAAA,0BAAU,EAAC,WAAW,CAAC,CAAC;YAE3C,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC;gBACnB,OAAO;oBACL,OAAO,EAAE,KAAK;oBACd,WAAW,EAAE,EAAE;oBACf,OAAO,EAAE,IAAI,CAAC,kBAAkB,EAAE;oBAClC,MAAM,EAAE;wBACN,CAAC,IAAI,CAAC,CAAC,CAAC,qBAAqB,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE;wBAC/C,CAAC,IAAI,CAAC,CAAC,CAAC,qBAAqB,WAAW,EAAE,CAAC,CAAC,CAAC,EAAE;qBAChD,CAAC,MAAM,CAAC,OAAO,CAAC;iBAClB,CAAC;YACJ,CAAC;YAED,MAAM,WAAW,GAAG,IAAI,CAAC,kBAAkB,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;YACjE,MAAM,OAAO,GAAG,IAAI,CAAC,cAAc,CAAC,WAAW,CAAC,CAAC;YAEjD,OAAO;gBACL,OAAO,EAAE,IAAI;gBACb,WAAW,EAAE,OAAO,CAAC,eAAe;oBAClC,CAAC,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC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AM,KAAK,OAAO,CAAC,CAAC,MAAM;YAC3D,OAAO,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,SAAS,CAAC,CAAC,MAAM;YAC/D,QAAQ,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,UAAU,CAAC,CAAC,MAAM;YACjE,SAAS,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,KAAK,WAAW,CAAC,CAAC,MAAM;SACpE,CAAC;IACJ,CAAC;IAED;;OAEG;IACK,kBAAkB;QACxB,OAAO;YACL,gBAAgB,EAAE,CAAC;YACnB,KAAK,EAAE,CAAC;YACR,OAAO,EAAE,CAAC;YACV,QAAQ,EAAE,CAAC;YACX,SAAS,EAAE,CAAC;SACb,CAAC;IACJ,CAAC;CACF;AAnND,gCAmNC"}
|
|
@@ -1,101 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Export System for Augment Extensions
|
|
3
|
-
* Handles exporting modules, configurations, and workspaces
|
|
4
|
-
* Also serves as the backup mechanism for AI context modules
|
|
5
|
-
*/
|
|
6
|
-
/**
|
|
7
|
-
* Export format types
|
|
8
|
-
*/
|
|
9
|
-
export type ExportFormat = 'json' | 'yaml' | 'tar' | 'zip';
|
|
10
|
-
/**
|
|
11
|
-
* Export options
|
|
12
|
-
*/
|
|
13
|
-
export interface ExportOptions {
|
|
14
|
-
/** Output file path (default: stdout) */
|
|
15
|
-
output?: string;
|
|
16
|
-
/** Output path (alias for output) */
|
|
17
|
-
outputPath?: string;
|
|
18
|
-
/** Export format */
|
|
19
|
-
format?: ExportFormat;
|
|
20
|
-
/** Include dependencies */
|
|
21
|
-
includeDeps?: boolean;
|
|
22
|
-
/** Include linked modules */
|
|
23
|
-
includeLinked?: boolean;
|
|
24
|
-
/** Include configuration */
|
|
25
|
-
includeConfig?: boolean;
|
|
26
|
-
/** Create bundled archive */
|
|
27
|
-
bundle?: boolean;
|
|
28
|
-
/** Compress output */
|
|
29
|
-
compress?: boolean;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Export result
|
|
33
|
-
*/
|
|
34
|
-
export interface ExportResult {
|
|
35
|
-
success: boolean;
|
|
36
|
-
outputPath?: string;
|
|
37
|
-
format: ExportFormat;
|
|
38
|
-
size?: number;
|
|
39
|
-
errors?: string[];
|
|
40
|
-
metadata?: {
|
|
41
|
-
format: string;
|
|
42
|
-
size: number;
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
|
-
/**
|
|
46
|
-
* Module export data
|
|
47
|
-
*/
|
|
48
|
-
export interface ModuleExportData {
|
|
49
|
-
metadata: any;
|
|
50
|
-
rules: {
|
|
51
|
-
[filename: string]: string;
|
|
52
|
-
};
|
|
53
|
-
examples: {
|
|
54
|
-
[filename: string]: string;
|
|
55
|
-
};
|
|
56
|
-
dependencies?: string[];
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Export System class
|
|
60
|
-
*/
|
|
61
|
-
export declare class ExportSystem {
|
|
62
|
-
private modulesDir;
|
|
63
|
-
constructor();
|
|
64
|
-
/**
|
|
65
|
-
* Export a single module
|
|
66
|
-
*/
|
|
67
|
-
exportModule(moduleName: string, options?: ExportOptions): Promise<ExportResult>;
|
|
68
|
-
/**
|
|
69
|
-
* Export configuration
|
|
70
|
-
*/
|
|
71
|
-
exportConfig(options?: ExportOptions): Promise<ExportResult>;
|
|
72
|
-
/**
|
|
73
|
-
* Export all linked modules
|
|
74
|
-
*/
|
|
75
|
-
exportLinked(options?: ExportOptions): Promise<ExportResult>;
|
|
76
|
-
/**
|
|
77
|
-
* Export entire workspace
|
|
78
|
-
*/
|
|
79
|
-
exportWorkspace(options?: ExportOptions): Promise<ExportResult>;
|
|
80
|
-
/**
|
|
81
|
-
* Prepare module export data
|
|
82
|
-
*/
|
|
83
|
-
private prepareModuleExport;
|
|
84
|
-
/**
|
|
85
|
-
* Write export data to file or stdout
|
|
86
|
-
*/
|
|
87
|
-
private writeExport;
|
|
88
|
-
/**
|
|
89
|
-
* Create archive (tar or zip)
|
|
90
|
-
*/
|
|
91
|
-
private createArchive;
|
|
92
|
-
/**
|
|
93
|
-
* Convert object to YAML format (simple implementation)
|
|
94
|
-
*/
|
|
95
|
-
private toYAML;
|
|
96
|
-
/**
|
|
97
|
-
* Get linked modules from .augment directory
|
|
98
|
-
*/
|
|
99
|
-
private getLinkedModules;
|
|
100
|
-
}
|
|
101
|
-
//# sourceMappingURL=export-system.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"export-system.d.ts","sourceRoot":"","sources":["../../src/utils/export-system.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAQH;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,MAAM,GAAG,KAAK,GAAG,KAAK,CAAC;AAE3D;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,yCAAyC;IACzC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,qCAAqC;IACrC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oBAAoB;IACpB,MAAM,CAAC,EAAE,YAAY,CAAC;IACtB,2BAA2B;IAC3B,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,6BAA6B;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,4BAA4B;IAC5B,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,6BAA6B;IAC7B,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,sBAAsB;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,YAAY,CAAC;IACrB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB,QAAQ,CAAC,EAAE;QACT,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;KACd,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,EAAE,GAAG,CAAC;IACd,KAAK,EAAE;QAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACtC,QAAQ,EAAE;QAAE,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACzC,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;CACzB;AAED;;GAEG;AACH,qBAAa,YAAY;IACvB,OAAO,CAAC,UAAU,CAAS;;IAM3B;;OAEG;IACG,YAAY,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,YAAY,CAAC;IAsB1F;;OAEG;IACG,YAAY,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,YAAY,CAAC;IActE;;OAEG;IACG,YAAY,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,YAAY,CAAC;IAsBtE;;OAEG;IACG,eAAe,CAAC,OAAO,GAAE,aAAkB,GAAG,OAAO,CAAC,YAAY,CAAC;IAmBzE;;OAEG;YACW,mBAAmB;IA6BjC;;OAEG;YACW,WAAW;IAyCzB;;OAEG;YACW,aAAa;IA8C3B;;OAEG;IACH,OAAO,CAAC,MAAM;IAoBd;;OAEG;YACW,gBAAgB;CAY/B"}
|
|
@@ -1,289 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* Export System for Augment Extensions
|
|
4
|
-
* Handles exporting modules, configurations, and workspaces
|
|
5
|
-
* Also serves as the backup mechanism for AI context modules
|
|
6
|
-
*/
|
|
7
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
8
|
-
if (k2 === undefined) k2 = k;
|
|
9
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
10
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
11
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
12
|
-
}
|
|
13
|
-
Object.defineProperty(o, k2, desc);
|
|
14
|
-
}) : (function(o, m, k, k2) {
|
|
15
|
-
if (k2 === undefined) k2 = k;
|
|
16
|
-
o[k2] = m[k];
|
|
17
|
-
}));
|
|
18
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
19
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
20
|
-
}) : function(o, v) {
|
|
21
|
-
o["default"] = v;
|
|
22
|
-
});
|
|
23
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
24
|
-
var ownKeys = function(o) {
|
|
25
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
26
|
-
var ar = [];
|
|
27
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
28
|
-
return ar;
|
|
29
|
-
};
|
|
30
|
-
return ownKeys(o);
|
|
31
|
-
};
|
|
32
|
-
return function (mod) {
|
|
33
|
-
if (mod && mod.__esModule) return mod;
|
|
34
|
-
var result = {};
|
|
35
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
36
|
-
__setModuleDefault(result, mod);
|
|
37
|
-
return result;
|
|
38
|
-
};
|
|
39
|
-
})();
|
|
40
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
41
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
42
|
-
};
|
|
43
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
44
|
-
exports.ExportSystem = void 0;
|
|
45
|
-
const fs = __importStar(require("fs"));
|
|
46
|
-
const path = __importStar(require("path"));
|
|
47
|
-
const archiver_1 = __importDefault(require("archiver"));
|
|
48
|
-
const module_system_1 = require("./module-system");
|
|
49
|
-
const config_system_1 = require("./config-system");
|
|
50
|
-
/**
|
|
51
|
-
* Export System class
|
|
52
|
-
*/
|
|
53
|
-
class ExportSystem {
|
|
54
|
-
constructor() {
|
|
55
|
-
this.modulesDir = (0, module_system_1.getModulesDir)();
|
|
56
|
-
}
|
|
57
|
-
/**
|
|
58
|
-
* Export a single module
|
|
59
|
-
*/
|
|
60
|
-
async exportModule(moduleName, options = {}) {
|
|
61
|
-
try {
|
|
62
|
-
const module = await (0, module_system_1.loadModule)(moduleName);
|
|
63
|
-
if (!module) {
|
|
64
|
-
return {
|
|
65
|
-
success: false,
|
|
66
|
-
format: options.format || 'json',
|
|
67
|
-
errors: [`Module not found: ${moduleName}`]
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
const exportData = await this.prepareModuleExport(module, options.includeDeps);
|
|
71
|
-
return await this.writeExport(exportData, options);
|
|
72
|
-
}
|
|
73
|
-
catch (error) {
|
|
74
|
-
return {
|
|
75
|
-
success: false,
|
|
76
|
-
format: options.format || 'json',
|
|
77
|
-
errors: [error instanceof Error ? error.message : String(error)]
|
|
78
|
-
};
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
/**
|
|
82
|
-
* Export configuration
|
|
83
|
-
*/
|
|
84
|
-
async exportConfig(options = {}) {
|
|
85
|
-
try {
|
|
86
|
-
const configManager = new config_system_1.ConfigManager();
|
|
87
|
-
const config = configManager.getConfig();
|
|
88
|
-
return await this.writeExport(config, options);
|
|
89
|
-
}
|
|
90
|
-
catch (error) {
|
|
91
|
-
return {
|
|
92
|
-
success: false,
|
|
93
|
-
format: options.format || 'json',
|
|
94
|
-
errors: [error instanceof Error ? error.message : String(error)]
|
|
95
|
-
};
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
/**
|
|
99
|
-
* Export all linked modules
|
|
100
|
-
*/
|
|
101
|
-
async exportLinked(options = {}) {
|
|
102
|
-
try {
|
|
103
|
-
const linkedModules = await this.getLinkedModules();
|
|
104
|
-
const exportData = {};
|
|
105
|
-
for (const moduleName of linkedModules) {
|
|
106
|
-
const module = await (0, module_system_1.loadModule)(moduleName);
|
|
107
|
-
if (module) {
|
|
108
|
-
exportData[moduleName] = await this.prepareModuleExport(module, false);
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
return await this.writeExport(exportData, options);
|
|
112
|
-
}
|
|
113
|
-
catch (error) {
|
|
114
|
-
return {
|
|
115
|
-
success: false,
|
|
116
|
-
format: options.format || 'json',
|
|
117
|
-
errors: [error instanceof Error ? error.message : String(error)]
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
/**
|
|
122
|
-
* Export entire workspace
|
|
123
|
-
*/
|
|
124
|
-
async exportWorkspace(options = {}) {
|
|
125
|
-
try {
|
|
126
|
-
const workspaceData = {
|
|
127
|
-
config: new config_system_1.ConfigManager().getConfig(),
|
|
128
|
-
linkedModules: await this.exportLinked({ ...options, output: undefined }),
|
|
129
|
-
timestamp: new Date().toISOString(),
|
|
130
|
-
version: '1.0.0'
|
|
131
|
-
};
|
|
132
|
-
return await this.writeExport(workspaceData, options);
|
|
133
|
-
}
|
|
134
|
-
catch (error) {
|
|
135
|
-
return {
|
|
136
|
-
success: false,
|
|
137
|
-
format: options.format || 'json',
|
|
138
|
-
errors: [error instanceof Error ? error.message : String(error)]
|
|
139
|
-
};
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
/**
|
|
143
|
-
* Prepare module export data
|
|
144
|
-
*/
|
|
145
|
-
async prepareModuleExport(module, includeDeps = false) {
|
|
146
|
-
const exportData = {
|
|
147
|
-
metadata: module.metadata,
|
|
148
|
-
rules: {},
|
|
149
|
-
examples: {}
|
|
150
|
-
};
|
|
151
|
-
// Read rule files
|
|
152
|
-
for (const ruleFile of module.rules) {
|
|
153
|
-
const content = fs.readFileSync(ruleFile, 'utf-8');
|
|
154
|
-
const filename = path.basename(ruleFile);
|
|
155
|
-
exportData.rules[filename] = content;
|
|
156
|
-
}
|
|
157
|
-
// Read example files
|
|
158
|
-
for (const exampleFile of module.examples) {
|
|
159
|
-
const content = fs.readFileSync(exampleFile, 'utf-8');
|
|
160
|
-
const filename = path.basename(exampleFile);
|
|
161
|
-
exportData.examples[filename] = content;
|
|
162
|
-
}
|
|
163
|
-
// Include dependencies if requested
|
|
164
|
-
if (includeDeps && module.metadata.dependencies) {
|
|
165
|
-
exportData.dependencies = module.metadata.dependencies;
|
|
166
|
-
}
|
|
167
|
-
return exportData;
|
|
168
|
-
}
|
|
169
|
-
/**
|
|
170
|
-
* Write export data to file or stdout
|
|
171
|
-
*/
|
|
172
|
-
async writeExport(data, options) {
|
|
173
|
-
const format = options.format || 'json';
|
|
174
|
-
if (options.bundle && (format === 'tar' || format === 'zip')) {
|
|
175
|
-
return await this.createArchive(data, options);
|
|
176
|
-
}
|
|
177
|
-
let output;
|
|
178
|
-
switch (format) {
|
|
179
|
-
case 'json':
|
|
180
|
-
output = JSON.stringify(data, null, 2);
|
|
181
|
-
break;
|
|
182
|
-
case 'yaml':
|
|
183
|
-
output = this.toYAML(data);
|
|
184
|
-
break;
|
|
185
|
-
default:
|
|
186
|
-
return {
|
|
187
|
-
success: false,
|
|
188
|
-
format,
|
|
189
|
-
errors: [`Unsupported format for non-archive export: ${format}`]
|
|
190
|
-
};
|
|
191
|
-
}
|
|
192
|
-
if (options.output) {
|
|
193
|
-
fs.writeFileSync(options.output, output, 'utf-8');
|
|
194
|
-
return {
|
|
195
|
-
success: true,
|
|
196
|
-
outputPath: options.output,
|
|
197
|
-
format,
|
|
198
|
-
size: Buffer.byteLength(output, 'utf-8')
|
|
199
|
-
};
|
|
200
|
-
}
|
|
201
|
-
else {
|
|
202
|
-
console.log(output);
|
|
203
|
-
return {
|
|
204
|
-
success: true,
|
|
205
|
-
format,
|
|
206
|
-
size: Buffer.byteLength(output, 'utf-8')
|
|
207
|
-
};
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
/**
|
|
211
|
-
* Create archive (tar or zip)
|
|
212
|
-
*/
|
|
213
|
-
async createArchive(data, options) {
|
|
214
|
-
return new Promise((resolve, reject) => {
|
|
215
|
-
if (!options.output) {
|
|
216
|
-
resolve({
|
|
217
|
-
success: false,
|
|
218
|
-
format: options.format || 'tar',
|
|
219
|
-
errors: ['Archive export requires output path']
|
|
220
|
-
});
|
|
221
|
-
return;
|
|
222
|
-
}
|
|
223
|
-
const format = options.format === 'zip' ? 'zip' : 'tar';
|
|
224
|
-
const archive = (0, archiver_1.default)(format, {
|
|
225
|
-
zlib: options.compress ? { level: 9 } : undefined
|
|
226
|
-
});
|
|
227
|
-
const output = fs.createWriteStream(options.output);
|
|
228
|
-
let totalSize = 0;
|
|
229
|
-
output.on('close', () => {
|
|
230
|
-
resolve({
|
|
231
|
-
success: true,
|
|
232
|
-
outputPath: options.output,
|
|
233
|
-
format: options.format || 'tar',
|
|
234
|
-
size: totalSize
|
|
235
|
-
});
|
|
236
|
-
});
|
|
237
|
-
archive.on('error', (err) => {
|
|
238
|
-
resolve({
|
|
239
|
-
success: false,
|
|
240
|
-
format: options.format || 'tar',
|
|
241
|
-
errors: [err.message]
|
|
242
|
-
});
|
|
243
|
-
});
|
|
244
|
-
archive.on('data', (chunk) => {
|
|
245
|
-
totalSize += chunk.length;
|
|
246
|
-
});
|
|
247
|
-
archive.pipe(output);
|
|
248
|
-
archive.append(JSON.stringify(data, null, 2), { name: 'export.json' });
|
|
249
|
-
archive.finalize();
|
|
250
|
-
});
|
|
251
|
-
}
|
|
252
|
-
/**
|
|
253
|
-
* Convert object to YAML format (simple implementation)
|
|
254
|
-
*/
|
|
255
|
-
toYAML(obj, indent = 0) {
|
|
256
|
-
const spaces = ' '.repeat(indent);
|
|
257
|
-
let yaml = '';
|
|
258
|
-
for (const [key, value] of Object.entries(obj)) {
|
|
259
|
-
if (typeof value === 'object' && value !== null && !Array.isArray(value)) {
|
|
260
|
-
yaml += `${spaces}${key}:\n${this.toYAML(value, indent + 2)}`;
|
|
261
|
-
}
|
|
262
|
-
else if (Array.isArray(value)) {
|
|
263
|
-
yaml += `${spaces}${key}:\n`;
|
|
264
|
-
for (const item of value) {
|
|
265
|
-
yaml += `${spaces} - ${item}\n`;
|
|
266
|
-
}
|
|
267
|
-
}
|
|
268
|
-
else {
|
|
269
|
-
yaml += `${spaces}${key}: ${value}\n`;
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
return yaml;
|
|
273
|
-
}
|
|
274
|
-
/**
|
|
275
|
-
* Get linked modules from .augment directory
|
|
276
|
-
*/
|
|
277
|
-
async getLinkedModules() {
|
|
278
|
-
const augmentDir = path.join(process.cwd(), '.augment');
|
|
279
|
-
const linkedFile = path.join(augmentDir, 'linked-modules.json');
|
|
280
|
-
if (!fs.existsSync(linkedFile)) {
|
|
281
|
-
return [];
|
|
282
|
-
}
|
|
283
|
-
const content = fs.readFileSync(linkedFile, 'utf-8');
|
|
284
|
-
const linked = JSON.parse(content);
|
|
285
|
-
return linked.modules || [];
|
|
286
|
-
}
|
|
287
|
-
}
|
|
288
|
-
exports.ExportSystem = ExportSystem;
|
|
289
|
-
//# sourceMappingURL=export-system.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"export-system.js","sourceRoot":"","sources":["../../src/utils/export-system.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2CAA6B;AAC7B,wDAAgC;AAChC,mDAAoE;AACpE,mDAAgD;AAsDhD;;GAEG;AACH,MAAa,YAAY;IAGvB;QACE,IAAI,CAAC,UAAU,GAAG,IAAA,6BAAa,GAAE,CAAC;IACpC,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,YAAY,CAAC,UAAkB,EAAE,UAAyB,EAAE;QAChE,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAA,0BAAU,EAAC,UAAU,CAA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