vibesuite 1.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/agent-recovery/SKILL.md +147 -0
- package/.agent/skills/code-review/SKILL.md +81 -0
- package/.agent/skills/component-analysis/SKILL.md +103 -0
- package/.agent/skills/git-worktree/SKILL.md +78 -0
- package/.agent/skills/github-ops/SKILL.md +220 -0
- package/.agent/skills/github-ops/scripts/publish_issues.ps1 +443 -0
- package/.agent/skills/github-ops/scripts/smart-ops.ps1 +128 -0
- package/.agent/skills/github-ops/scripts/smart-ops.sh +130 -0
- package/.agent/skills/google-trends/SKILL.md +157 -0
- package/.agent/skills/google-trends/scripts/node_modules/.modules.yaml +21 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/LICENSE +22 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/Readme.md +1157 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/esm.mjs +16 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/index.js +24 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/argument.js +149 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/command.js +2509 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/error.js +39 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/help.js +520 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/option.js +330 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/lib/suggestSimilar.js +101 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/package-support.json +16 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/package.json +84 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/typings/esm.d.mts +3 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/commander@12.1.0/node_modules/commander/typings/index.d.ts +969 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/CHANGES.md +132 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/LICENSE +21 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/README.md +561 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/lib/google-trends-api.min.js +2 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/package.json +68 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/src/api.js +18 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/src/index.js +27 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/src/request.js +69 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/google-trends-api@4.9.2/node_modules/google-trends-api/src/utilities.js +395 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm/lock.yaml +31 -0
- package/.agent/skills/google-trends/scripts/node_modules/.pnpm-workspace-state-v1.json +25 -0
- package/.agent/skills/google-trends/scripts/package.json +17 -0
- package/.agent/skills/google-trends/scripts/pnpm-lock.yaml +31 -0
- package/.agent/skills/google-trends/scripts/search.js +168 -0
- package/.agent/skills/high-fidelity-extraction/SKILL.md +59 -0
- package/.agent/skills/prime-agent/SKILL.md +97 -0
- package/.agent/skills/security-audit/SKILL.md +81 -0
- package/.agent/skills/seo-ready/SKILL.md +133 -0
- package/.agent/skills/spawn-task/SKILL.md +130 -0
- package/.agent/skills/sync-docs/SKILL.md +88 -0
- package/.agent/skills/vercel-ai-sdk/SKILL.md +34083 -0
- package/.agent/skills/youtube-pipeline/SKILL.md +194 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase1-strategy.md +224 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase2-packaging.md +148 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase3-scripting.md +197 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase3.5-shorts.md +271 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase4-production.md +193 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-phase5-repurposing.md +159 -0
- package/.agent/skills/youtube-pipeline/resources/youtube-pipeline.md +161 -0
- package/.agent/skills/youtube-pipeline/scripts/parse_yt_studio.ps1 +150 -0
- package/.agent/workflows/LEGACY/ANTIGRAVITY_TOOLBOX.md +200 -0
- package/.agent/workflows/LEGACY/analyze_component.md +141 -0
- package/.agent/workflows/LEGACY/build_vibecode_project.md +154 -0
- package/.agent/workflows/LEGACY/deep_code_audit.md +79 -0
- package/.agent/workflows/LEGACY/gemini-orchestrate.md +63 -0
- package/.agent/workflows/LEGACY/git_worktree.md +71 -0
- package/.agent/workflows/LEGACY/init_smart_ops.md +101 -0
- package/.agent/workflows/LEGACY/multi_agent_strategy.md +62 -0
- package/.agent/workflows/LEGACY/orchestrate.md +321 -0
- package/.agent/workflows/LEGACY/seo_ready.md +249 -0
- package/.agent/workflows/LEGACY/vibe-orchestrator.md +305 -0
- package/.agent/workflows/LEGACY/youtube-phase1-strategy.md +224 -0
- package/.agent/workflows/LEGACY/youtube-phase2-packaging.md +148 -0
- package/.agent/workflows/LEGACY/youtube-phase3-scripting.md +197 -0
- package/.agent/workflows/LEGACY/youtube-phase3.5-shorts.md +271 -0
- package/.agent/workflows/LEGACY/youtube-phase4-production.md +193 -0
- package/.agent/workflows/LEGACY/youtube-phase5-repurposing.md +159 -0
- package/.agent/workflows/LEGACY/youtube-pipeline.md +161 -0
- package/.agent/workflows/README.md +349 -0
- package/.agent/workflows/Vercel Ai SDK.md +34083 -0
- package/.agent/workflows/agent_reset.md +138 -0
- package/.agent/workflows/build_vibecode_project_v2.md +158 -0
- package/.agent/workflows/escalate.md +112 -0
- package/.agent/workflows/init_vibecode_design.md +98 -0
- package/.agent/workflows/init_vibecode_genesis.md +137 -0
- package/.agent/workflows/migrate.md +135 -0
- package/.agent/workflows/prime_agent.md +211 -0
- package/.agent/workflows/reverse_genesis.md +132 -0
- package/.agent/workflows/review_code.md +133 -0
- package/.agent/workflows/spawn-jstar-code-review.md +121 -0
- package/.agent/workflows/spawn_task.md +187 -0
- package/.agent/workflows/sync_docs.md +90 -0
- package/Legacy (Manual Method)/0 VibeCode User Manual.md +173 -0
- package/Legacy (Manual Method)/1 Project Genesis Protocol The VibeCode Workflow.md +89 -0
- package/Legacy (Manual Method)/2/342/234/250 ULTIMATE ORCHESTRATION PROMPT/342/234/250.md" +114 -0
- package/Legacy (Manual Method)/3 Design System Genesis Protocol.md +75 -0
- package/Legacy (Manual Method)/3.1.1 my_design_system_rules.md +177 -0
- package/Legacy (Manual Method)/3.1.2 Material You M3 Genesis Protocol.md +73 -0
- package/Legacy (Manual Method)/4 The Ultimate GitHub Issue Meta-Prompt Template.md +54 -0
- package/Legacy (Manual Method)/5 The Escalation & Handoff Protocol.md +97 -0
- package/Legacy (Manual Method)/8 The Seamless Migration Meta-Prompt (Your Reusable Tool).md +38 -0
- package/Legacy (Manual Method)/9 The Reverse Genesis Protocol.md +75 -0
- package/README.md +209 -0
- package/VibeCode-Agents (e.g Kilo-code)/README.md +142 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-analyzer.yaml +254 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-architect.yaml +397 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-auditor.yaml +325 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-builder.yaml +472 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-designer.yaml +305 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-documentor.yaml +222 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-escalator.yaml +255 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-isolator.yaml +332 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-onboarder.yaml +335 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-orchestrator.yaml +365 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-orchestrator_legacy.yaml +284 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-orchestrator_v1.yaml +336 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-primer.yaml +213 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-reviewer.yaml +233 -0
- package/VibeCode-Agents (e.g Kilo-code)/vibe-spawner.yaml +259 -0
- package/bin/vibesuite.js +2 -0
- package/package.json +43 -0
- package/src/cli.js +159 -0
- package/src/utils.js +76 -0
package/package.json
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "vibesuite",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "A Complete System for AI-Human Software Development Collaboration",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"vibesuite": "./bin/vibesuite.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"bin",
|
|
11
|
+
"src",
|
|
12
|
+
".agent",
|
|
13
|
+
"VibeCode-Agents (e.g Kilo-code)",
|
|
14
|
+
"Legacy (Manual Method)"
|
|
15
|
+
],
|
|
16
|
+
"scripts": {
|
|
17
|
+
"test": "echo \"Error: no test specified\" && exit 1"
|
|
18
|
+
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "git+https://github.com/JStaRFilms/VibeCode-Protocol-Suite.git"
|
|
22
|
+
},
|
|
23
|
+
"keywords": [
|
|
24
|
+
"ai",
|
|
25
|
+
"vibecode",
|
|
26
|
+
"cursor",
|
|
27
|
+
"windsurf",
|
|
28
|
+
"protocols"
|
|
29
|
+
],
|
|
30
|
+
"author": "J StaR Films Studios",
|
|
31
|
+
"license": "ISC",
|
|
32
|
+
"dependencies": {
|
|
33
|
+
"commander": "^13.1.0",
|
|
34
|
+
"figlet": "^1.8.0",
|
|
35
|
+
"fs-extra": "^11.3.0",
|
|
36
|
+
"picocolors": "^1.1.1",
|
|
37
|
+
"prompts": "^2.4.2"
|
|
38
|
+
},
|
|
39
|
+
"bugs": {
|
|
40
|
+
"url": "https://github.com/JStaRFilms/VibeCode-Protocol-Suite/issues"
|
|
41
|
+
},
|
|
42
|
+
"homepage": "https://github.com/JStaRFilms/VibeCode-Protocol-Suite#readme"
|
|
43
|
+
}
|
package/src/cli.js
ADDED
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import { Command } from 'commander';
|
|
2
|
+
import prompts from 'prompts';
|
|
3
|
+
import pc from 'picocolors';
|
|
4
|
+
import figlet from 'figlet';
|
|
5
|
+
import fs from 'fs-extra';
|
|
6
|
+
import path from 'path';
|
|
7
|
+
import { PATHS, getWorkflows, getSkills, copyToDestination, copySpecificWorkflows, copySpecificSkills } from './utils.js';
|
|
8
|
+
|
|
9
|
+
const program = new Command();
|
|
10
|
+
|
|
11
|
+
async function init() {
|
|
12
|
+
console.log(pc.magenta(figlet.textSync('VibeSuite', { horizontalLayout: 'full' })));
|
|
13
|
+
console.log(pc.cyan(' J StaR Films Studios VibeCode Protocol Suite\n'));
|
|
14
|
+
|
|
15
|
+
const response = await prompts([
|
|
16
|
+
{
|
|
17
|
+
type: 'multiselect',
|
|
18
|
+
name: 'components',
|
|
19
|
+
message: 'What components do you want to spawn?',
|
|
20
|
+
choices: [
|
|
21
|
+
{ title: '.agent Folder (Workflows & Skills)', value: 'agent', selected: true, description: 'Recommended for Cursor/Windsurf' },
|
|
22
|
+
{ title: 'Agent YAMLs', value: 'yamls', description: 'For Kilo Code / Deep Source' },
|
|
23
|
+
{ title: 'Legacy Manual Protocols', value: 'legacy', description: 'Browser-based prompts' }
|
|
24
|
+
],
|
|
25
|
+
min: 1,
|
|
26
|
+
hint: '- Space to select. Return to submit'
|
|
27
|
+
},
|
|
28
|
+
// Workflow Selection (Only if .agent is selected)
|
|
29
|
+
{
|
|
30
|
+
type: (prev, values) => values.components.includes('agent') ? 'select' : null,
|
|
31
|
+
name: 'workflowMode',
|
|
32
|
+
message: 'How should we install Workflows?',
|
|
33
|
+
choices: [
|
|
34
|
+
{ title: 'Install All Workflows', value: 'all' },
|
|
35
|
+
{ title: 'Install All (Exclude Legacy)', value: 'no-legacy' },
|
|
36
|
+
{ title: 'Select Specific Workflows', value: 'custom' }
|
|
37
|
+
]
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
type: (prev, values) => values.workflowMode === 'custom' ? 'multiselect' : null,
|
|
41
|
+
name: 'selectedWorkflows',
|
|
42
|
+
message: 'Select workflows to install:',
|
|
43
|
+
choices: async () => {
|
|
44
|
+
const workflows = await getWorkflows();
|
|
45
|
+
return workflows.map(w => ({ title: w, value: w }));
|
|
46
|
+
},
|
|
47
|
+
hint: '- Space to select. Return to submit'
|
|
48
|
+
},
|
|
49
|
+
// Skill Selection (Only if .agent is selected)
|
|
50
|
+
{
|
|
51
|
+
type: (prev, values) => values.components.includes('agent') ? 'select' : null,
|
|
52
|
+
name: 'skillMode',
|
|
53
|
+
message: 'How should we install Skills?',
|
|
54
|
+
choices: [
|
|
55
|
+
{ title: 'Install All Skills', value: 'all' },
|
|
56
|
+
{ title: 'Select Specific Skills', value: 'custom' }
|
|
57
|
+
]
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
type: (prev, values) => values.skillMode === 'custom' ? 'multiselect' : null,
|
|
61
|
+
name: 'selectedSkills',
|
|
62
|
+
message: 'Select skills to install:',
|
|
63
|
+
choices: async () => {
|
|
64
|
+
const skills = await getSkills();
|
|
65
|
+
return skills.map(s => ({ title: s, value: s }));
|
|
66
|
+
},
|
|
67
|
+
hint: '- Space to select. Return to submit'
|
|
68
|
+
},
|
|
69
|
+
// Destination
|
|
70
|
+
{
|
|
71
|
+
type: 'text',
|
|
72
|
+
name: 'path',
|
|
73
|
+
message: 'Where should we spawn these files?',
|
|
74
|
+
initial: './'
|
|
75
|
+
}
|
|
76
|
+
]);
|
|
77
|
+
|
|
78
|
+
if (!response.components) return; // User cancelled
|
|
79
|
+
|
|
80
|
+
const destRoot = path.resolve(process.cwd(), response.path);
|
|
81
|
+
console.log(pc.dim(`\nSpawning resources into: ${destRoot}...\n`));
|
|
82
|
+
|
|
83
|
+
try {
|
|
84
|
+
// 1. Handle .agent Folder
|
|
85
|
+
if (response.components.includes('agent')) {
|
|
86
|
+
const agentDest = path.join(destRoot, '.agent');
|
|
87
|
+
const workflowsDest = path.join(agentDest, 'workflows');
|
|
88
|
+
const skillsDest = path.join(agentDest, 'skills');
|
|
89
|
+
|
|
90
|
+
await fs.ensureDir(agentDest);
|
|
91
|
+
|
|
92
|
+
// Handle Workflows
|
|
93
|
+
if (response.workflowMode === 'all') {
|
|
94
|
+
console.log(pc.green('✔ Copying all workflows...'));
|
|
95
|
+
await fs.copy(PATHS.workflows, workflowsDest);
|
|
96
|
+
} else if (response.workflowMode === 'no-legacy') {
|
|
97
|
+
console.log(pc.green('✔ Copying workflows (skipping legacy)...'));
|
|
98
|
+
await fs.copy(PATHS.workflows, workflowsDest);
|
|
99
|
+
// Remove LEGACY folder if it exists in the copy
|
|
100
|
+
const legacyPath = path.join(workflowsDest, 'LEGACY');
|
|
101
|
+
if (await fs.pathExists(legacyPath)) {
|
|
102
|
+
await fs.remove(legacyPath);
|
|
103
|
+
}
|
|
104
|
+
} else if (response.workflowMode === 'custom' && response.selectedWorkflows) {
|
|
105
|
+
console.log(pc.green(`✔ Copying ${response.selectedWorkflows.length} specific workflows...`));
|
|
106
|
+
await copySpecificWorkflows(response.selectedWorkflows, workflowsDest);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
// Handle Skills
|
|
110
|
+
if (response.skillMode === 'all') {
|
|
111
|
+
console.log(pc.green('✔ Copying all skills...'));
|
|
112
|
+
await fs.copy(PATHS.skills, skillsDest);
|
|
113
|
+
} else if (response.skillMode === 'custom' && response.selectedSkills) {
|
|
114
|
+
console.log(pc.green(`✔ Copying ${response.selectedSkills.length} specific skills...`));
|
|
115
|
+
await copySpecificSkills(response.selectedSkills, skillsDest);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// Copy .agent/README.md if it exists
|
|
119
|
+
const readmeSrc = path.join(PATHS.agent, 'README.md');
|
|
120
|
+
if (await fs.pathExists(readmeSrc)) {
|
|
121
|
+
await fs.copy(readmeSrc, path.join(agentDest, 'README.md'));
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// 2. Handle Agent YAMLs
|
|
126
|
+
if (response.components.includes('yamls')) {
|
|
127
|
+
console.log(pc.green('✔ Copying Agent YAMLs...'));
|
|
128
|
+
const yamlDest = path.join(destRoot, 'VibeCode-Agents');
|
|
129
|
+
await fs.copy(PATHS.agentsYaml, yamlDest);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
// 3. Handle Legacy Manual
|
|
133
|
+
if (response.components.includes('legacy')) {
|
|
134
|
+
console.log(pc.green('✔ Copying Legacy Protocols...'));
|
|
135
|
+
const legacyDest = path.join(destRoot, 'Legacy-Protocols');
|
|
136
|
+
await fs.copy(PATHS.manual, legacyDest);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
console.log(pc.magenta('\n✨ VibeCode Protocol Suite spawned successfully! ✨'));
|
|
140
|
+
console.log(pc.white(`\nNext steps:`));
|
|
141
|
+
if (response.components.includes('agent')) {
|
|
142
|
+
console.log(pc.gray(`1. If using Cursor/Windsurf, the .agent folder is ready.`));
|
|
143
|
+
console.log(pc.gray(`2. Try typing '/init_vibecode_genesis' in your IDE.`));
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
} catch (error) {
|
|
147
|
+
console.error(pc.red('Error during installation:'), error);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
program
|
|
152
|
+
.name('vibesuite')
|
|
153
|
+
.description('VibeCode Protocol Suite CLI')
|
|
154
|
+
.version('1.0.0')
|
|
155
|
+
.command('init')
|
|
156
|
+
.description('Initialize VibeCode in the current directory')
|
|
157
|
+
.action(init);
|
|
158
|
+
|
|
159
|
+
program.parse();
|
package/src/utils.js
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import fs from 'fs-extra';
|
|
2
|
+
import path from 'path';
|
|
3
|
+
import { fileURLToPath } from 'url';
|
|
4
|
+
|
|
5
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
6
|
+
const __dirname = path.dirname(__filename);
|
|
7
|
+
// Root of the package (up one level from src/)
|
|
8
|
+
const PACKAGE_ROOT = path.resolve(__dirname, '..');
|
|
9
|
+
|
|
10
|
+
export const PATHS = {
|
|
11
|
+
root: PACKAGE_ROOT,
|
|
12
|
+
agent: path.join(PACKAGE_ROOT, '.agent'),
|
|
13
|
+
workflows: path.join(PACKAGE_ROOT, '.agent', 'workflows'),
|
|
14
|
+
skills: path.join(PACKAGE_ROOT, '.agent', 'skills'),
|
|
15
|
+
agentsYaml: path.join(PACKAGE_ROOT, 'VibeCode-Agents (e.g Kilo-code)'),
|
|
16
|
+
manual: path.join(PACKAGE_ROOT, 'Legacy (Manual Method)'),
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export async function getWorkflows() {
|
|
20
|
+
try {
|
|
21
|
+
const files = await fs.readdir(PATHS.workflows);
|
|
22
|
+
// filter out directories if any, keep .md files
|
|
23
|
+
return files.filter(f => f.endsWith('.md'));
|
|
24
|
+
} catch (error) {
|
|
25
|
+
return [];
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export async function getSkills() {
|
|
30
|
+
try {
|
|
31
|
+
const files = await fs.readdir(PATHS.skills);
|
|
32
|
+
// skills are directories
|
|
33
|
+
const skills = [];
|
|
34
|
+
for (const file of files) {
|
|
35
|
+
const stats = await fs.stat(path.join(PATHS.skills, file));
|
|
36
|
+
if (stats.isDirectory()) {
|
|
37
|
+
skills.push(file);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
return skills;
|
|
41
|
+
} catch (error) {
|
|
42
|
+
return [];
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export async function copyToDestination(source, dest) {
|
|
47
|
+
try {
|
|
48
|
+
await fs.copy(source, dest, { overwrite: true });
|
|
49
|
+
return true;
|
|
50
|
+
} catch (error) {
|
|
51
|
+
console.error(`Error copying ${source} to ${dest}:`, error);
|
|
52
|
+
return false;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export async function copySpecificWorkflows(selectedWorkflows, destFolder) {
|
|
57
|
+
// Ensure dest folder exists
|
|
58
|
+
await fs.ensureDir(destFolder);
|
|
59
|
+
|
|
60
|
+
for (const workflow of selectedWorkflows) {
|
|
61
|
+
const src = path.join(PATHS.workflows, workflow);
|
|
62
|
+
const dest = path.join(destFolder, workflow);
|
|
63
|
+
await fs.copy(src, dest, { overwrite: true });
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export async function copySpecificSkills(selectedSkills, destFolder) {
|
|
68
|
+
// Ensure dest folder exists
|
|
69
|
+
await fs.ensureDir(destFolder);
|
|
70
|
+
|
|
71
|
+
for (const skill of selectedSkills) {
|
|
72
|
+
const src = path.join(PATHS.skills, skill);
|
|
73
|
+
const dest = path.join(destFolder, skill);
|
|
74
|
+
await fs.copy(src, dest, { overwrite: true });
|
|
75
|
+
}
|
|
76
|
+
}
|