gsd-antigravity-kit 1.32.0 → 2.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.
- package/.agent/skills/gsd/SKILL.md +152 -123
- package/.agent/skills/gsd/VERSION +1 -0
- package/.agent/skills/gsd/assets/templates/user-profile.md +8 -8
- package/.agent/skills/gsd/bin/gsd-tools.cjs +81 -3
- package/.agent/skills/gsd/bin/help-manifest.json +24 -1
- package/.agent/skills/gsd/bin/hooks/gsd-check-update.js +15 -5
- package/.agent/skills/gsd/bin/hooks/gsd-context-monitor.js +1 -1
- package/.agent/skills/gsd/bin/hooks/gsd-phase-boundary.sh +27 -0
- package/.agent/skills/gsd/bin/hooks/gsd-prompt-guard.js +2 -1
- package/.agent/skills/gsd/bin/hooks/gsd-read-guard.js +1 -1
- package/.agent/skills/gsd/bin/hooks/gsd-session-state.sh +33 -0
- package/.agent/skills/gsd/bin/hooks/gsd-statusline.js +5 -5
- package/.agent/skills/gsd/bin/hooks/gsd-validate-commit.sh +47 -0
- package/.agent/skills/gsd/bin/hooks/gsd-workflow-guard.js +1 -1
- package/.agent/skills/gsd/bin/lib/config.cjs +31 -10
- package/.agent/skills/gsd/bin/lib/core.cjs +48 -13
- package/.agent/skills/gsd/bin/lib/frontmatter.cjs +34 -2
- package/.agent/skills/gsd/bin/lib/intel.cjs +660 -0
- package/.agent/skills/gsd/bin/lib/learnings.cjs +378 -0
- package/.agent/skills/gsd/bin/lib/milestone.cjs +13 -4
- package/.agent/skills/gsd/bin/lib/model-profiles.cjs +17 -17
- package/.agent/skills/gsd/bin/lib/profile-output.cjs +31 -31
- package/.agent/skills/gsd/bin/lib/security.cjs +119 -0
- package/.agent/skills/gsd/bin/lib/verify.cjs +15 -15
- package/.agent/skills/gsd/migration_report.md +7 -0
- package/.agent/skills/gsd/references/agents/gsd-code-fixer.md +516 -0
- package/.agent/skills/gsd/references/agents/gsd-code-reviewer.md +355 -0
- package/.agent/skills/gsd/references/agents/gsd-debugger.md +10 -1
- package/.agent/skills/gsd/references/agents/gsd-executor.md +3 -0
- package/.agent/skills/gsd/references/agents/gsd-intel-updater.md +314 -0
- package/.agent/skills/gsd/references/agents/gsd-phase-researcher.md +3 -0
- package/.agent/skills/gsd/references/agents/gsd-plan-checker.md +16 -4
- package/.agent/skills/gsd/references/agents/gsd-planner.md +7 -0
- package/.agent/skills/gsd/references/agents/gsd-user-profiler.md +5 -5
- package/.agent/skills/gsd/references/agents/gsd-verifier.md +55 -1
- package/.agent/skills/gsd/references/agents/profiles/dev.md +21 -0
- package/.agent/skills/gsd/references/agents/profiles/research.md +22 -0
- package/.agent/skills/gsd/references/agents/profiles/review.md +22 -0
- package/.agent/skills/gsd/references/commands/{gsd-add-todo.md → atomic/add-todo.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-check-todos.md → atomic/check-todos.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-cleanup.md → atomic/cleanup.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-do.md → atomic/do.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-help.md → atomic/help.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-join-discord.md → atomic/join-discord.md} +21 -19
- package/.agent/skills/gsd/references/commands/{gsd-note.md → atomic/note.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-session-report.md → atomic/session-report.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-ship.md → atomic/ship.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-stats.md → atomic/stats.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-thread.md → atomic/thread.md} +7 -6
- package/.agent/skills/gsd/references/commands/atomic/undo.md +36 -0
- package/.agent/skills/gsd/references/commands/{gsd-add-backlog.md → milestone/add-backlog.md} +8 -7
- package/.agent/skills/gsd/references/commands/{gsd-audit-milestone.md → milestone/audit-milestone.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-complete-milestone.md → milestone/complete-milestone.md} +6 -4
- package/.agent/skills/gsd/references/commands/{gsd-milestone-summary.md → milestone/milestone-summary.md} +5 -3
- package/.agent/skills/gsd/references/commands/{gsd-new-milestone.md → milestone/new-milestone.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-plan-milestone-gaps.md → milestone/plan-milestone-gaps.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-plant-seed.md → milestone/plant-seed.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-review-backlog.md → milestone/review-backlog.md} +6 -5
- package/.agent/skills/gsd/references/commands/misc/audit-fix.md +35 -0
- package/.agent/skills/gsd/references/commands/{gsd-audit-uat.md → misc/audit-uat.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-next.md → misc/next.md} +6 -3
- package/.agent/skills/gsd/references/commands/{gsd-progress.md → misc/progress.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-verify-work.md → misc/verify-work.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-add-phase.md → phase/add-phase.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-add-tests.md → phase/add-tests.md} +8 -3
- package/.agent/skills/gsd/references/commands/{gsd-discuss-phase.md → phase/discuss-phase.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-execute-phase.md → phase/execute-phase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-insert-phase.md → phase/insert-phase.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-list-phase-assumptions.md → phase/list-phase-assumptions.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-plan-phase.md → phase/plan-phase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-remove-phase.md → phase/remove-phase.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-research-phase.md → phase/research-phase.md} +7 -6
- package/.agent/skills/gsd/references/commands/{gsd-secure-phase.md → phase/secure-phase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-ui-phase.md → phase/ui-phase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-ui-review.md → phase/ui-review.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-validate-phase.md → phase/validate-phase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-workstreams.md → phase/workstreams.md} +71 -70
- package/.agent/skills/gsd/references/commands/{gsd-analyze-dependencies.md → project/analyze-dependencies.md} +5 -4
- package/.agent/skills/gsd/references/commands/project/explore.md +29 -0
- package/.agent/skills/gsd/references/commands/project/import.md +38 -0
- package/.agent/skills/gsd/references/commands/project/intel.md +181 -0
- package/.agent/skills/gsd/references/commands/{gsd-list-workspaces.md → project/list-workspaces.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-map-codebase.md → project/map-codebase.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-new-project.md → project/new-project.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-new-workspace.md → project/new-workspace.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-remove-workspace.md → project/remove-workspace.md} +4 -3
- package/.agent/skills/gsd/references/commands/project/scan.md +28 -0
- package/.agent/skills/gsd/references/commands/{gsd-autonomous.md → system/autonomous.md} +4 -3
- package/.agent/skills/gsd/references/commands/system/code-review-fix.md +54 -0
- package/.agent/skills/gsd/references/commands/system/code-review.md +57 -0
- package/.agent/skills/gsd/references/commands/{gsd-debug.md → system/debug.md} +7 -6
- package/.agent/skills/gsd/references/commands/{gsd-docs-update.md → system/docs-update.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-fast.md → system/fast.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-forensics.md → system/forensics.md} +5 -3
- package/.agent/skills/gsd/references/commands/{gsd-health.md → system/health.md} +5 -4
- package/.agent/skills/gsd/references/commands/{gsd-manager.md → system/manager.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-pause-work.md → system/pause-work.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-pr-branch.md → system/pr-branch.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-profile-user.md → system/profile-user.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-quick.md → system/quick.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-reapply-patches.md → system/reapply-patches.md} +25 -7
- package/.agent/skills/gsd/references/commands/{gsd-resume-work.md → system/resume-work.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-review.md → system/review.md} +4 -3
- package/.agent/skills/gsd/references/commands/system/set-profile.md +14 -0
- package/.agent/skills/gsd/references/commands/{gsd-settings.md → system/settings.md} +4 -3
- package/.agent/skills/gsd/references/commands/{gsd-update.md → system/update.md} +4 -3
- package/.agent/skills/gsd/references/docs/agent-contracts.md +79 -0
- package/.agent/skills/gsd/references/docs/common-bug-patterns.md +114 -0
- package/.agent/skills/gsd/references/docs/context-budget.md +49 -0
- package/.agent/skills/gsd/references/docs/domain-probes.md +125 -0
- package/.agent/skills/gsd/references/docs/few-shot-examples/plan-checker.md +73 -0
- package/.agent/skills/gsd/references/docs/few-shot-examples/verifier.md +109 -0
- package/.agent/skills/gsd/references/docs/gate-prompts.md +100 -0
- package/.agent/skills/gsd/references/docs/gates.md +70 -0
- package/.agent/skills/gsd/references/docs/model-profile-resolution.md +2 -0
- package/.agent/skills/gsd/references/docs/model-profiles.md +20 -14
- package/.agent/skills/gsd/references/docs/planning-config.md +216 -1
- package/.agent/skills/gsd/references/docs/revision-loop.md +97 -0
- package/.agent/skills/gsd/references/docs/thinking-models-debug.md +44 -0
- package/.agent/skills/gsd/references/docs/thinking-models-execution.md +50 -0
- package/.agent/skills/gsd/references/docs/thinking-models-planning.md +62 -0
- package/.agent/skills/gsd/references/docs/thinking-models-research.md +50 -0
- package/.agent/skills/gsd/references/docs/thinking-models-verification.md +55 -0
- package/.agent/skills/gsd/references/docs/thinking-partner.md +96 -0
- package/.agent/skills/gsd/references/docs/universal-anti-patterns.md +58 -0
- package/.agent/skills/gsd/references/docs/user-profiling.md +10 -10
- package/.agent/skills/gsd/references/docs/verification-overrides.md +227 -0
- package/.agent/skills/gsd/references/docs/workstream-flag.md +2 -2
- package/.agent/skills/gsd/references/mapping.md +11 -21
- package/.agent/skills/gsd/references/workflows/analyze-dependencies.md +3 -3
- package/.agent/skills/gsd/references/workflows/audit-fix.md +157 -0
- package/.agent/skills/gsd/references/workflows/autonomous.md +22 -1
- package/.agent/skills/gsd/references/workflows/code-review-fix.md +497 -0
- package/.agent/skills/gsd/references/workflows/code-review.md +515 -0
- package/.agent/skills/gsd/references/workflows/discuss-phase-power.md +3 -3
- package/.agent/skills/gsd/references/workflows/discuss-phase.md +20 -0
- package/.agent/skills/gsd/references/workflows/execute-phase.md +103 -0
- package/.agent/skills/gsd/references/workflows/explore.md +139 -0
- package/.agent/skills/gsd/references/workflows/import.md +274 -0
- package/.agent/skills/gsd/references/workflows/inbox.md +384 -0
- package/.agent/skills/gsd/references/workflows/manager.md +5 -5
- package/.agent/skills/gsd/references/workflows/new-milestone.md +1 -1
- package/.agent/skills/gsd/references/workflows/next.md +56 -0
- package/.agent/skills/gsd/references/workflows/plan-phase.md +48 -1
- package/.agent/skills/gsd/references/workflows/quick.md +96 -2
- package/.agent/skills/gsd/references/workflows/review.md +23 -3
- package/.agent/skills/gsd/references/workflows/scan.md +102 -0
- package/.agent/skills/gsd/references/workflows/settings.md +1 -1
- package/.agent/skills/gsd/references/workflows/ui-review.md +2 -2
- package/.agent/skills/gsd/references/workflows/undo.md +312 -0
- package/.agent/skills/gsd/references/workflows/update.md +5 -5
- package/.agent/skills/gsd-converter/SKILL.md +67 -59
- package/.agent/skills/gsd-converter/assets/migration-manifest.json +74 -0
- package/.agent/skills/gsd-converter/references/mapping.md +6 -16
- package/.agent/skills/gsd-converter/scripts/convert.py +419 -80
- package/.agent/skills/gsd-converter/scripts/regression_test.py +33 -0
- package/.agent/skills/selectpaste-update/SKILL.md +46 -0
- package/.agent/skills/selectpaste-update/scripts/sync-commands.py +317 -0
- package/README.md +4 -2
- package/bin/install.js +116 -116
- package/package.json +1 -1
- package/.agent/skills/gsd/references/commands/gsd-set-profile.md +0 -12
- /package/.agent/skills/gsd/references/commands/{gsd-tools.md → system/gsd-tools.md} +0 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: selectpaste-update
|
|
3
|
+
description: "Specialized maintenance skill to synchronize GSD command registries with remote documentation and local backups. Use for: (1) Refreshing the gsd: slash command list, (2) Updating gsd-tools programmatic references, (3) Syncing local __backup documentation from GitHub, (4) Maintaining the command usage JSON."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# selectpaste-update
|
|
7
|
+
|
|
8
|
+
## Purpose
|
|
9
|
+
|
|
10
|
+
The **selectpaste-update** skill automates the synchronization between the GSD documentation and the programmatic command registry used by GSD tools and UI components. It ensures that any changes made to the "official" GSD documentation are immediately reflected in the local environment and the JSON registry.
|
|
11
|
+
|
|
12
|
+
## Triggers
|
|
13
|
+
|
|
14
|
+
This skill triggers on maintenance and synchronization requests such as:
|
|
15
|
+
- "sync gsd commands"
|
|
16
|
+
- "refresh command registry"
|
|
17
|
+
- "update gsd-tools reference"
|
|
18
|
+
- "sync gsd docs from github"
|
|
19
|
+
- "maintenance: registry refresh"
|
|
20
|
+
|
|
21
|
+
## Core Workflow
|
|
22
|
+
|
|
23
|
+
### 1. Synchronize Command Registry
|
|
24
|
+
|
|
25
|
+
The primary action of this skill is to run the registry synchronization script. This process performs the following steps:
|
|
26
|
+
1. **Fetch**: Downloads the latest `COMMANDS.md` and `CLI-TOOLS.md` from the `gsd-build/get-shit-done` repository.
|
|
27
|
+
2. **Local Sync**: Updates `__backup/COMMANDS.md` and `__backup/CLI-TOOLS.md` with the fetched content.
|
|
28
|
+
3. **Backup**: Creates a `.bak` timestamped copy of the existing `__backup/commands.json`.
|
|
29
|
+
4. **Merge**: Parses the Markdown files and merges new data into `commands.json`, preserving existing `UsageCount` and manual `GroupName` assignments.
|
|
30
|
+
|
|
31
|
+
**Command:**
|
|
32
|
+
```powershell
|
|
33
|
+
py .agent/skills/selectpaste-update/scripts/sync-commands.py
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## Best Practices
|
|
37
|
+
|
|
38
|
+
- **Verify Before Sync**: If you have local modifications in `__backup/` that are not yet on GitHub, run with the `--local` flag to prevent overwriting them.
|
|
39
|
+
- **Review Diffs**: Always review the git diff for `__backup/commands.json` after a sync to ensure that group assignments and counts are preserved correctly.
|
|
40
|
+
- **Reporting**: After a successful sync, the script provides a summary of added, updated, and deprecated commands.
|
|
41
|
+
|
|
42
|
+
## Reference Material
|
|
43
|
+
|
|
44
|
+
- [COMMANDS.md](file:///c:/projects/GSD-Antigravity/__backup/COMMANDS.md) - Slash command reference
|
|
45
|
+
- [CLI-TOOLS.md](file:///c:/projects/GSD-Antigravity/__backup/CLI-TOOLS.md) - Programmatic tools reference
|
|
46
|
+
- [commands.json](file:///c:/projects/GSD-Antigravity/__backup/commands.json) - The generated registry
|
|
@@ -0,0 +1,317 @@
|
|
|
1
|
+
import json
|
|
2
|
+
import os
|
|
3
|
+
import re
|
|
4
|
+
import urllib.request
|
|
5
|
+
from datetime import datetime
|
|
6
|
+
import shutil
|
|
7
|
+
import sys
|
|
8
|
+
|
|
9
|
+
# Configuration
|
|
10
|
+
CONFIG = {
|
|
11
|
+
"backup_dir": "__backup",
|
|
12
|
+
"json_file": "commands.json",
|
|
13
|
+
"md_commands": "COMMANDS.md",
|
|
14
|
+
"md_cli": "CLI-TOOLS.md",
|
|
15
|
+
"remote_commands": "https://raw.githubusercontent.com/gsd-build/get-shit-done/main/docs/COMMANDS.md",
|
|
16
|
+
"remote_cli": "https://raw.githubusercontent.com/gsd-build/get-shit-done/main/docs/CLI-TOOLS.md"
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
def fetch_url(url):
|
|
20
|
+
try:
|
|
21
|
+
with urllib.request.urlopen(url) as response:
|
|
22
|
+
return response.read().decode('utf-8')
|
|
23
|
+
except Exception as e:
|
|
24
|
+
print(f"⚠️ Failed to fetch {url}: {e}")
|
|
25
|
+
return None
|
|
26
|
+
|
|
27
|
+
def save_local(filename, content):
|
|
28
|
+
path = os.path.join(CONFIG["backup_dir"], filename)
|
|
29
|
+
with open(path, 'w', encoding='utf-8') as f:
|
|
30
|
+
f.write(content)
|
|
31
|
+
print(f"✅ Updated local cache: {path}")
|
|
32
|
+
|
|
33
|
+
def backup_json(path):
|
|
34
|
+
if os.path.exists(path):
|
|
35
|
+
timestamp = datetime.now().strftime("%Y%m%d_%H%M%S")
|
|
36
|
+
backup_path = f"{path}.{timestamp}.bak"
|
|
37
|
+
shutil.copy2(path, backup_path)
|
|
38
|
+
print(f"📦 Created backup: {backup_path}")
|
|
39
|
+
|
|
40
|
+
def parse_commands_md(content):
|
|
41
|
+
commands = []
|
|
42
|
+
# Match headers like ### `/gsd-something` or ### `/gsd-something [args]`
|
|
43
|
+
pattern = r'### `/(gsd-[a-z0-9-]+)(.*?)`'
|
|
44
|
+
sections = re.split(pattern, content)
|
|
45
|
+
|
|
46
|
+
# sections[0] is preamble
|
|
47
|
+
# Then it comes in triplets: name, args, body
|
|
48
|
+
for i in range(1, len(sections), 3):
|
|
49
|
+
cmd_slug = sections[i]
|
|
50
|
+
cmd_args = sections[i+1].strip()
|
|
51
|
+
body = sections[i+2].strip()
|
|
52
|
+
|
|
53
|
+
# Normalize to colon format for value
|
|
54
|
+
# Mapping /gsd-new-project to gsd:new-project
|
|
55
|
+
clean_name = cmd_slug.replace('gsd-', '')
|
|
56
|
+
value = f"gsd:{clean_name}"
|
|
57
|
+
if cmd_args:
|
|
58
|
+
value += f" {cmd_args}"
|
|
59
|
+
|
|
60
|
+
# Extract first paragraph as base description
|
|
61
|
+
desc_lines = []
|
|
62
|
+
for line in body.split('\n'):
|
|
63
|
+
if line.strip() and not line.startswith('|') and not line.startswith('**'):
|
|
64
|
+
desc_lines.append(line.strip())
|
|
65
|
+
if len(desc_lines) > 2: # Keep it concise
|
|
66
|
+
break
|
|
67
|
+
|
|
68
|
+
description = " ".join(desc_lines)
|
|
69
|
+
|
|
70
|
+
# Extract example if exists
|
|
71
|
+
examples = re.findall(r'```bash\n(.*?)\n```', body, re.DOTALL)
|
|
72
|
+
if examples:
|
|
73
|
+
description += f"\n\nExample:\n{examples[0].strip()}"
|
|
74
|
+
|
|
75
|
+
commands.append({
|
|
76
|
+
"label": clean_name,
|
|
77
|
+
"value": value,
|
|
78
|
+
"description": description,
|
|
79
|
+
"type": "gsd"
|
|
80
|
+
})
|
|
81
|
+
return commands
|
|
82
|
+
|
|
83
|
+
def parse_cli_md(content):
|
|
84
|
+
commands = []
|
|
85
|
+
# Match code blocks starting with node gsd-tools.cjs
|
|
86
|
+
pattern = r'node gsd-tools\.cjs (.*?)(?=\n|#|$)'
|
|
87
|
+
matches = re.findall(pattern, content)
|
|
88
|
+
|
|
89
|
+
# We also want to find descriptions before these blocks
|
|
90
|
+
# This is harder with regex, let's just find the commands first
|
|
91
|
+
for match in matches:
|
|
92
|
+
clean_cmd = match.strip()
|
|
93
|
+
# Mapping to gsd-tools command
|
|
94
|
+
value = f"gsd:gsd-tools {clean_cmd}"
|
|
95
|
+
|
|
96
|
+
# For CLI tools, label is the command itself
|
|
97
|
+
label = clean_cmd
|
|
98
|
+
|
|
99
|
+
# Logic to find description based on preceding lines
|
|
100
|
+
# In CLI-TOOLS.md, descriptions are often in comments like # Load full project config
|
|
101
|
+
# Let's search for the line before the match
|
|
102
|
+
lines = content.split('\n')
|
|
103
|
+
desc = ""
|
|
104
|
+
for i, line in enumerate(lines):
|
|
105
|
+
if f"node gsd-tools.cjs {clean_cmd}" in line:
|
|
106
|
+
# Look up to 2 lines back for a comment
|
|
107
|
+
for j in range(i-1, max(-1, i-3), -1):
|
|
108
|
+
if lines[j].strip().startswith('#'):
|
|
109
|
+
desc = lines[j].strip().lstrip('#').strip()
|
|
110
|
+
break
|
|
111
|
+
break
|
|
112
|
+
|
|
113
|
+
commands.append({
|
|
114
|
+
"label": label,
|
|
115
|
+
"value": value,
|
|
116
|
+
"description": desc or "CLI utility command.",
|
|
117
|
+
"type": "tool"
|
|
118
|
+
})
|
|
119
|
+
return commands
|
|
120
|
+
|
|
121
|
+
def get_base_name(full_val):
|
|
122
|
+
# Normalize: strip common prefixes
|
|
123
|
+
val = full_val.strip()
|
|
124
|
+
|
|
125
|
+
# 1. Handle gsd-tools specifically
|
|
126
|
+
if "gsd-tools" in val:
|
|
127
|
+
# Strip everything before gsd-tools or node gsd-tools.cjs
|
|
128
|
+
clean = re.sub(r'.*?gsd-tools(\.cjs)?\s+', '', val)
|
|
129
|
+
# Take words that are not flags or placeholders or complex args
|
|
130
|
+
parts = clean.split(' ')
|
|
131
|
+
res = []
|
|
132
|
+
for p in parts:
|
|
133
|
+
if not p or p.startswith('-') or '<' in p or '[' in p or '@' in p or '|' in p or '(' in p:
|
|
134
|
+
break
|
|
135
|
+
res.append(p)
|
|
136
|
+
return "gsd-tools " + " ".join(res).strip()
|
|
137
|
+
|
|
138
|
+
# 2. Handle slash commands
|
|
139
|
+
if val.startswith('/') or val.startswith('gsd:'):
|
|
140
|
+
clean = re.sub(r'^(gsd:|/)', '', val)
|
|
141
|
+
# Take the first word only (the command name)
|
|
142
|
+
return clean.split(' ')[0].strip()
|
|
143
|
+
|
|
144
|
+
# 3. Fallback
|
|
145
|
+
return val.split(' ')[0].strip()
|
|
146
|
+
|
|
147
|
+
def sync():
|
|
148
|
+
is_local = "--local" in sys.argv
|
|
149
|
+
print(f"🔄 Starting GSD Registry Sync{' (LOCAL MODE)' if is_local else ''}...")
|
|
150
|
+
|
|
151
|
+
# 1. & 2. Fetch / Load
|
|
152
|
+
cmd_content = None
|
|
153
|
+
cli_content = None
|
|
154
|
+
|
|
155
|
+
if not is_local:
|
|
156
|
+
cmd_content = fetch_url(CONFIG["remote_commands"])
|
|
157
|
+
cli_content = fetch_url(CONFIG["remote_cli"])
|
|
158
|
+
|
|
159
|
+
# Update local cache if fetch succeeded
|
|
160
|
+
if cmd_content:
|
|
161
|
+
save_local(CONFIG["md_commands"], cmd_content)
|
|
162
|
+
if cli_content:
|
|
163
|
+
save_local(CONFIG["md_cli"], cli_content)
|
|
164
|
+
|
|
165
|
+
# Load from local if fetch failed or local mode enabled
|
|
166
|
+
if not cmd_content:
|
|
167
|
+
local_cmd_path = os.path.join(CONFIG["backup_dir"], CONFIG["md_commands"])
|
|
168
|
+
if os.path.exists(local_cmd_path):
|
|
169
|
+
print(f"ℹ️ Loading local {CONFIG['md_commands']}.")
|
|
170
|
+
with open(local_cmd_path, 'r', encoding='utf-8') as f:
|
|
171
|
+
cmd_content = f.read()
|
|
172
|
+
|
|
173
|
+
if not cli_content:
|
|
174
|
+
local_cli_path = os.path.join(CONFIG["backup_dir"], CONFIG["md_cli"])
|
|
175
|
+
if os.path.exists(local_cli_path):
|
|
176
|
+
print(f"ℹ️ Loading local {CONFIG['md_cli']}.")
|
|
177
|
+
with open(local_cli_path, 'r', encoding='utf-8') as f:
|
|
178
|
+
cli_content = f.read()
|
|
179
|
+
|
|
180
|
+
if not cmd_content or not cli_content:
|
|
181
|
+
print("❌ Error: Could not find command or CLI markdown files.")
|
|
182
|
+
return
|
|
183
|
+
|
|
184
|
+
# 3. Backup JSON
|
|
185
|
+
json_path = os.path.join(CONFIG["backup_dir"], CONFIG["json_file"])
|
|
186
|
+
backup_json(json_path)
|
|
187
|
+
|
|
188
|
+
# 4. Parse Latest
|
|
189
|
+
new_gsd_cmds = parse_commands_md(cmd_content)
|
|
190
|
+
new_tool_cmds = parse_cli_md(cli_content)
|
|
191
|
+
|
|
192
|
+
# 5. Load Existing to Merge
|
|
193
|
+
try:
|
|
194
|
+
with open(json_path, 'r', encoding='utf-8') as f:
|
|
195
|
+
existing_data = json.load(f)
|
|
196
|
+
except Exception as e:
|
|
197
|
+
print(f"⚠️ Failed to load existing JSON: {e}")
|
|
198
|
+
existing_data = []
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
# Flatten existing for easier lookup by base command
|
|
202
|
+
# We prioritize non-"NEW" groups if duplicates exist
|
|
203
|
+
existing_map = {}
|
|
204
|
+
for group in existing_data:
|
|
205
|
+
gname = group["name"]
|
|
206
|
+
is_new_group = gname.startswith("[NEW]")
|
|
207
|
+
|
|
208
|
+
for cmd in group.get("commands", []):
|
|
209
|
+
base_name = get_base_name(cmd.get("value", ""))
|
|
210
|
+
|
|
211
|
+
# If we haven't seen this base yet, or if previous was from a [NEW] group
|
|
212
|
+
# but current isn't, overwrite to prioritize the permanent group
|
|
213
|
+
if base_name not in existing_map or (existing_map[base_name]["IsNewGroup"] and not is_new_group):
|
|
214
|
+
existing_map[base_name] = {
|
|
215
|
+
"Metadata": cmd,
|
|
216
|
+
"Group": gname,
|
|
217
|
+
"IsNewGroup": is_new_group
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
# 6. Merge & Classify
|
|
221
|
+
groups = {g["name"]: g for g in existing_data}
|
|
222
|
+
|
|
223
|
+
# Global Deduplication:
|
|
224
|
+
# Ensure each command only exists in its most specialized group (favor non-"NEW" groups)
|
|
225
|
+
for base_name, match_info in existing_map.items():
|
|
226
|
+
primary_group = match_info["Group"]
|
|
227
|
+
for gname in groups:
|
|
228
|
+
if gname != primary_group:
|
|
229
|
+
groups[gname]["commands"] = [
|
|
230
|
+
d for d in groups[gname]["commands"]
|
|
231
|
+
if get_base_name(d["value"]) != base_name
|
|
232
|
+
]
|
|
233
|
+
|
|
234
|
+
# Ensure staging groups exist
|
|
235
|
+
if "[NEW] GSD COMMANDS" not in groups:
|
|
236
|
+
groups["[NEW] GSD COMMANDS"] = {"name": "[NEW] GSD COMMANDS", "description": "Newly discovered slash commands.", "commands": []}
|
|
237
|
+
if "[NEW] GSD-TOOLS" not in groups:
|
|
238
|
+
groups["[NEW] GSD-TOOLS"] = {"name": "[NEW] GSD-TOOLS", "description": "Newly discovered gsd-tools commands.", "commands": []}
|
|
239
|
+
|
|
240
|
+
processed_names = set()
|
|
241
|
+
|
|
242
|
+
def merge_cmd(new_cmd, default_group):
|
|
243
|
+
full_val = new_cmd["value"]
|
|
244
|
+
base_name = get_base_name(full_val)
|
|
245
|
+
processed_names.add(base_name)
|
|
246
|
+
|
|
247
|
+
if base_name in existing_map:
|
|
248
|
+
# Update existing
|
|
249
|
+
old_cmd = existing_map[base_name]["Metadata"]
|
|
250
|
+
group_name = existing_map[base_name]["Group"]
|
|
251
|
+
|
|
252
|
+
# Preserve numeric prefix if label has one
|
|
253
|
+
label = new_cmd["label"]
|
|
254
|
+
match = re.match(r'^(\d+\.)\s*(.*)', old_cmd.get("label", ""))
|
|
255
|
+
if match:
|
|
256
|
+
label = f"{match.group(1)} {label}"
|
|
257
|
+
|
|
258
|
+
updated_cmd = {
|
|
259
|
+
"label": label,
|
|
260
|
+
"value": full_val, # Use new value (with potentially updated args)
|
|
261
|
+
"description": new_cmd["description"],
|
|
262
|
+
"GroupName": group_name,
|
|
263
|
+
"UsageCount": old_cmd.get("UsageCount", 0),
|
|
264
|
+
"FullDisplay": f"[{group_name.upper()}] {label} -> {full_val}",
|
|
265
|
+
"TabDisplay": f"{label} -> {full_val}"
|
|
266
|
+
}
|
|
267
|
+
# Put back in the right group
|
|
268
|
+
# Clear ANY other old versions just in case
|
|
269
|
+
groups[group_name]["commands"] = [
|
|
270
|
+
d for d in groups[group_name]["commands"]
|
|
271
|
+
if get_base_name(d["value"]) != base_name
|
|
272
|
+
]
|
|
273
|
+
groups[group_name]["commands"].append(updated_cmd)
|
|
274
|
+
else:
|
|
275
|
+
# Add to staged
|
|
276
|
+
new_entry = {
|
|
277
|
+
"label": new_cmd["label"],
|
|
278
|
+
"value": full_val,
|
|
279
|
+
"description": new_cmd["description"],
|
|
280
|
+
"GroupName": default_group,
|
|
281
|
+
"UsageCount": 0,
|
|
282
|
+
"FullDisplay": f"[{default_group.upper()}] {new_cmd['label']} -> {full_val}",
|
|
283
|
+
"TabDisplay": f"{new_cmd['label']} -> {full_val}"
|
|
284
|
+
}
|
|
285
|
+
groups[default_group]["commands"].append(new_entry)
|
|
286
|
+
|
|
287
|
+
for cmd in new_gsd_cmds:
|
|
288
|
+
merge_cmd(cmd, "[NEW] GSD COMMANDS")
|
|
289
|
+
|
|
290
|
+
for cmd in new_tool_cmds:
|
|
291
|
+
merge_cmd(cmd, "[NEW] GSD-TOOLS")
|
|
292
|
+
|
|
293
|
+
# Re-order commands in each group (numeric sort)
|
|
294
|
+
for gname in groups:
|
|
295
|
+
group = groups[gname]
|
|
296
|
+
group["commands"].sort(key=lambda x: x.get("label", ""))
|
|
297
|
+
|
|
298
|
+
# Convert groups back to list
|
|
299
|
+
# Preserve original group ordering
|
|
300
|
+
ordered_group_names = [g["name"] for g in existing_data]
|
|
301
|
+
for gname in groups:
|
|
302
|
+
if gname not in ordered_group_names:
|
|
303
|
+
ordered_group_names.append(gname)
|
|
304
|
+
|
|
305
|
+
final_output = [groups[name] for name in ordered_group_names if groups[name]["commands"]]
|
|
306
|
+
|
|
307
|
+
# 7. Write Result
|
|
308
|
+
with open(json_path, 'w', encoding='utf-8') as f:
|
|
309
|
+
json.dump(final_output, f, indent=2, ensure_ascii=False)
|
|
310
|
+
|
|
311
|
+
print(f"✨ Successfully synchronized {len(processed_names)} commands to {json_path}")
|
|
312
|
+
|
|
313
|
+
if __name__ == "__main__":
|
|
314
|
+
# Ensure backup dir exists
|
|
315
|
+
if not os.path.exists(CONFIG["backup_dir"]):
|
|
316
|
+
os.makedirs(CONFIG["backup_dir"])
|
|
317
|
+
sync()
|
package/README.md
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
[](https://opensource.org/licenses/MIT)
|
|
4
4
|
[](https://github.com/google-deepmind/antigravity)
|
|
5
5
|
[](https://www.npmjs.com/package/gsd-antigravity-kit)
|
|
6
|
-
[](https://github.com/dturkuler/GSD-Antigravity/releases/latest)
|
|
7
|
+
[](https://github.com/glittercowboy/get-shit-done)
|
|
8
8
|
|
|
9
9
|
**GSD-Antigravity Kit** is the official bootstrapping and management utility for the [Get Shit Done (GSD)](https://github.com/glittercowboy/get-shit-done) protocol within the Antigravity AI framework. It serves as a high-performance **Installer** and **Skill Manager** that provision, optimizes, and maintains GSD skills in your AG environment.
|
|
10
10
|
|
|
@@ -103,3 +103,5 @@ The core logic, philosophy, and original script engine were created by **[glitte
|
|
|
103
103
|
|
|
104
104
|
|
|
105
105
|
|
|
106
|
+
|
|
107
|
+
|
package/bin/install.js
CHANGED
|
@@ -1,116 +1,116 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
|
|
3
|
-
const fs = require('fs');
|
|
4
|
-
const path = require('path');
|
|
5
|
-
const readline = require('readline');
|
|
6
|
-
const { execSync } = require('child_process');
|
|
7
|
-
|
|
8
|
-
const rl = readline.createInterface({
|
|
9
|
-
input: process.stdin,
|
|
10
|
-
output: process.stdout
|
|
11
|
-
});
|
|
12
|
-
|
|
13
|
-
const ask = (query) => new Promise((resolve) => rl.question(query, (ans) => resolve(ans.toLowerCase().trim())));
|
|
14
|
-
|
|
15
|
-
async function install() {
|
|
16
|
-
const targetDir = process.cwd();
|
|
17
|
-
const sourceAgentDir = path.join(__dirname, '..', '.agent');
|
|
18
|
-
const skillsSourceDir = path.join(sourceAgentDir, 'skills');
|
|
19
|
-
|
|
20
|
-
// Skills to check/install
|
|
21
|
-
const skillNames = ['gsd', 'gsd-converter'];
|
|
22
|
-
const targetSkillsDir = path.join(targetDir, '.agent', 'skills');
|
|
23
|
-
|
|
24
|
-
console.log('\n🌌 GSD-Antigravity Skill System Installer\n');
|
|
25
|
-
|
|
26
|
-
try {
|
|
27
|
-
// 1. Check for existing skills
|
|
28
|
-
const existing = [];
|
|
29
|
-
for (const name of skillNames) {
|
|
30
|
-
if (fs.existsSync(path.join(targetSkillsDir, name))) {
|
|
31
|
-
existing.push(name);
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
if (existing.length > 0) {
|
|
36
|
-
console.log(`⚠️ Detected existing skills in .agent/skills/: ${existing.join(', ')}`);
|
|
37
|
-
const confirmRemove = await ask(`Do you want to REMOVE existing skills and perform a fresh install? (y/n): `);
|
|
38
|
-
if (confirmRemove === 'y') {
|
|
39
|
-
for (const name of existing) {
|
|
40
|
-
const p = path.join(targetSkillsDir, name);
|
|
41
|
-
console.log(` 🗑️ Removing ${name}...`);
|
|
42
|
-
fs.rmSync(p, { recursive: true, force: true });
|
|
43
|
-
}
|
|
44
|
-
} else {
|
|
45
|
-
console.log(' ⏩ Skipping removal. New files will be merged/overwritten.');
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// 2. Interactive Installation Selection
|
|
50
|
-
const installGsd = await ask(`Install GSD skill? (y/n) [default: y]: `);
|
|
51
|
-
const installConverter = await ask(`Install GSD-Converter skill? (y/n) [default: y]: `);
|
|
52
|
-
|
|
53
|
-
const selection = {
|
|
54
|
-
'gsd': installGsd !== 'n',
|
|
55
|
-
'gsd-converter': installConverter !== 'n'
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
// 3. Perform Installation
|
|
59
|
-
if (!fs.existsSync(targetSkillsDir)) {
|
|
60
|
-
fs.mkdirSync(targetSkillsDir, { recursive: true });
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
// Also copy rules if they exist
|
|
64
|
-
const sourceRulesDir = path.join(sourceAgentDir, 'rules');
|
|
65
|
-
const targetRulesDir = path.join(targetDir, '.agent', 'rules');
|
|
66
|
-
if (fs.existsSync(sourceRulesDir)) {
|
|
67
|
-
copyFolderSync(sourceRulesDir, targetRulesDir);
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
let installedCount = 0;
|
|
71
|
-
for (const [name, shouldInstall] of Object.entries(selection)) {
|
|
72
|
-
if (shouldInstall) {
|
|
73
|
-
const src = path.join(skillsSourceDir, name);
|
|
74
|
-
const tgt = path.join(targetSkillsDir, name);
|
|
75
|
-
if (fs.existsSync(src)) {
|
|
76
|
-
console.log(`📦 Installing ${name}...`);
|
|
77
|
-
copyFolderSync(src, tgt);
|
|
78
|
-
installedCount++;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
if (installedCount > 0) {
|
|
84
|
-
console.log('\n✅ Installation completed successfully.');
|
|
85
|
-
if (selection['gsd-converter']) {
|
|
86
|
-
console.log('\n✨ To initialize the GSD engine, run:');
|
|
87
|
-
console.log(' py .agent/skills/gsd-converter/scripts/convert.py gsd\n');
|
|
88
|
-
}
|
|
89
|
-
} else {
|
|
90
|
-
console.log('\nℹ️ No skills were selected for installation.');
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
} catch (err) {
|
|
94
|
-
console.error('\n❌ Installation failed:', err.message);
|
|
95
|
-
} finally {
|
|
96
|
-
rl.close();
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
function copyFolderSync(from, to) {
|
|
101
|
-
if (!fs.existsSync(to)) {
|
|
102
|
-
fs.mkdirSync(to, { recursive: true });
|
|
103
|
-
}
|
|
104
|
-
fs.readdirSync(from).forEach(element => {
|
|
105
|
-
const srcPath = path.join(from, element);
|
|
106
|
-
const tgtPath = path.join(to, element);
|
|
107
|
-
const stat = fs.lstatSync(srcPath);
|
|
108
|
-
if (stat.isFile()) {
|
|
109
|
-
fs.copyFileSync(srcPath, tgtPath);
|
|
110
|
-
} else if (stat.isDirectory()) {
|
|
111
|
-
copyFolderSync(srcPath, tgtPath);
|
|
112
|
-
}
|
|
113
|
-
});
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
install();
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const fs = require('fs');
|
|
4
|
+
const path = require('path');
|
|
5
|
+
const readline = require('readline');
|
|
6
|
+
const { execSync } = require('child_process');
|
|
7
|
+
|
|
8
|
+
const rl = readline.createInterface({
|
|
9
|
+
input: process.stdin,
|
|
10
|
+
output: process.stdout
|
|
11
|
+
});
|
|
12
|
+
|
|
13
|
+
const ask = (query) => new Promise((resolve) => rl.question(query, (ans) => resolve(ans.toLowerCase().trim())));
|
|
14
|
+
|
|
15
|
+
async function install() {
|
|
16
|
+
const targetDir = process.cwd();
|
|
17
|
+
const sourceAgentDir = path.join(__dirname, '..', '.agent');
|
|
18
|
+
const skillsSourceDir = path.join(sourceAgentDir, 'skills');
|
|
19
|
+
|
|
20
|
+
// Skills to check/install
|
|
21
|
+
const skillNames = ['gsd', 'gsd-converter'];
|
|
22
|
+
const targetSkillsDir = path.join(targetDir, '.agent', 'skills');
|
|
23
|
+
|
|
24
|
+
console.log('\n🌌 GSD-Antigravity Skill System Installer\n');
|
|
25
|
+
|
|
26
|
+
try {
|
|
27
|
+
// 1. Check for existing skills
|
|
28
|
+
const existing = [];
|
|
29
|
+
for (const name of skillNames) {
|
|
30
|
+
if (fs.existsSync(path.join(targetSkillsDir, name))) {
|
|
31
|
+
existing.push(name);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
if (existing.length > 0) {
|
|
36
|
+
console.log(`⚠️ Detected existing skills in .agent/skills/: ${existing.join(', ')}`);
|
|
37
|
+
const confirmRemove = await ask(`Do you want to REMOVE existing skills and perform a fresh install? (y/n): `);
|
|
38
|
+
if (confirmRemove === 'y') {
|
|
39
|
+
for (const name of existing) {
|
|
40
|
+
const p = path.join(targetSkillsDir, name);
|
|
41
|
+
console.log(` 🗑️ Removing ${name}...`);
|
|
42
|
+
fs.rmSync(p, { recursive: true, force: true });
|
|
43
|
+
}
|
|
44
|
+
} else {
|
|
45
|
+
console.log(' ⏩ Skipping removal. New files will be merged/overwritten.');
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
// 2. Interactive Installation Selection
|
|
50
|
+
const installGsd = await ask(`Install GSD skill? (y/n) [default: y]: `);
|
|
51
|
+
const installConverter = await ask(`Install GSD-Converter skill? (y/n) [default: y]: `);
|
|
52
|
+
|
|
53
|
+
const selection = {
|
|
54
|
+
'gsd': installGsd !== 'n',
|
|
55
|
+
'gsd-converter': installConverter !== 'n'
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
// 3. Perform Installation
|
|
59
|
+
if (!fs.existsSync(targetSkillsDir)) {
|
|
60
|
+
fs.mkdirSync(targetSkillsDir, { recursive: true });
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
// Also copy rules if they exist
|
|
64
|
+
const sourceRulesDir = path.join(sourceAgentDir, 'rules');
|
|
65
|
+
const targetRulesDir = path.join(targetDir, '.agent', 'rules');
|
|
66
|
+
if (fs.existsSync(sourceRulesDir)) {
|
|
67
|
+
copyFolderSync(sourceRulesDir, targetRulesDir);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
let installedCount = 0;
|
|
71
|
+
for (const [name, shouldInstall] of Object.entries(selection)) {
|
|
72
|
+
if (shouldInstall) {
|
|
73
|
+
const src = path.join(skillsSourceDir, name);
|
|
74
|
+
const tgt = path.join(targetSkillsDir, name);
|
|
75
|
+
if (fs.existsSync(src)) {
|
|
76
|
+
console.log(`📦 Installing ${name}...`);
|
|
77
|
+
copyFolderSync(src, tgt);
|
|
78
|
+
installedCount++;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
if (installedCount > 0) {
|
|
84
|
+
console.log('\n✅ Installation completed successfully.');
|
|
85
|
+
if (selection['gsd-converter']) {
|
|
86
|
+
console.log('\n✨ To initialize the GSD engine, run:');
|
|
87
|
+
console.log(' py .agent/skills/gsd-converter/scripts/convert.py gsd\n');
|
|
88
|
+
}
|
|
89
|
+
} else {
|
|
90
|
+
console.log('\nℹ️ No skills were selected for installation.');
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
} catch (err) {
|
|
94
|
+
console.error('\n❌ Installation failed:', err.message);
|
|
95
|
+
} finally {
|
|
96
|
+
rl.close();
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
function copyFolderSync(from, to) {
|
|
101
|
+
if (!fs.existsSync(to)) {
|
|
102
|
+
fs.mkdirSync(to, { recursive: true });
|
|
103
|
+
}
|
|
104
|
+
fs.readdirSync(from).forEach(element => {
|
|
105
|
+
const srcPath = path.join(from, element);
|
|
106
|
+
const tgtPath = path.join(to, element);
|
|
107
|
+
const stat = fs.lstatSync(srcPath);
|
|
108
|
+
if (stat.isFile()) {
|
|
109
|
+
fs.copyFileSync(srcPath, tgtPath);
|
|
110
|
+
} else if (stat.isDirectory()) {
|
|
111
|
+
copyFolderSync(srcPath, tgtPath);
|
|
112
|
+
}
|
|
113
|
+
});
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
install();
|
package/package.json
CHANGED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: gsd-set-profile
|
|
3
|
-
description: "Switch model profile for GSD agents (quality/balanced/budget/inherit)"
|
|
4
|
-
argument-hint: "<profile (quality|balanced|budget|inherit)>"
|
|
5
|
-
allowed-tools:
|
|
6
|
-
- Bash
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
Show the following output to the user verbatim, with no extra commentary:
|
|
11
|
-
|
|
12
|
-
!`node ".agent/skills/gsd/bin/gsd-tools.cjs" config-set-model-profile $ARGUMENTS --raw`
|
|
File without changes
|