Skip to content

Commit 75afc50

Browse files
authored
main to dev (#31)
* Add updater progress bar * Add updater progress bar (#24) * Dev (#25) * Add updater progress bar * Update overlay desktop icon assets * Dev (#26) * Add updater progress bar * Update overlay desktop icon assets * Add overlay delete confirmation dialog * Dev (#27) * Add updater progress bar * Update overlay desktop icon assets * Add overlay delete confirmation dialog * Make Windows install one-click * Sp/make windows install one click (#29) * added overlay iamge * Make Windows install one-click * Handle npm notices in Windows installer * added overlay iamge (#30) * Export portable Node runtime for Windows install * Fix Windows installer build and runtime
1 parent 332084d commit 75afc50

12 files changed

Lines changed: 431 additions & 89 deletions

File tree

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ curl.exe -fsSL -o install-superplan.cmd https://raw.githubusercontent.com/superp
4141
curl.exe -fsSL -o install-superplan.cmd https://raw.githubusercontent.com/superplan-md/superplan-plugin/main/scripts/install.cmd && install-superplan.cmd
4242
```
4343

44+
The Windows installer now installs the CLI and the packaged overlay companion, and it downloads and keeps a bundled Node runtime when needed so users do not need to preinstall Node.js just to get started.
45+
4446
After install, Superplan will ask if you want to run `superplan init`.
4547

4648
---

apps/desktop/build/icon.icns

16.7 KB
Binary file not shown.

apps/desktop/build/icon.ico

-47 Bytes
Binary file not shown.

apps/desktop/build/icon.png

56.7 KB
Loading

apps/desktop/resources/icon.png

56.7 KB
Loading

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"superplan": "./dist/cli/main.js"
1717
},
1818
"scripts": {
19-
"build": "tsc && node ./scripts/copy-skills.js && ./scripts/generate-outputs.sh",
19+
"build": "tsc && node ./scripts/copy-skills.js && node ./scripts/generate-outputs.js",
2020
"desktop:build": "pnpm --dir apps/desktop build",
2121
"desktop:dev": "pnpm --dir apps/desktop dev",
2222
"overlay:bundle": "node ./scripts/overlay-release.js build",

scripts/generate-outputs.js

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
1+
#!/usr/bin/env node
2+
3+
const fs = require('node:fs');
4+
const path = require('node:path');
5+
6+
const repoRoot = path.resolve(__dirname, '..');
7+
const outputDir = path.join(repoRoot, 'output');
8+
const skillsDir = path.join(outputDir, 'skills');
9+
10+
function ensureDirectory(targetPath) {
11+
fs.mkdirSync(targetPath, { recursive: true });
12+
}
13+
14+
function pathExists(targetPath) {
15+
return fs.existsSync(targetPath);
16+
}
17+
18+
function copyFile(sourcePath, destinationPath) {
19+
ensureDirectory(path.dirname(destinationPath));
20+
fs.copyFileSync(sourcePath, destinationPath);
21+
}
22+
23+
function listSkillFiles(rootPath) {
24+
const skillFiles = [];
25+
for (const entry of fs.readdirSync(rootPath, { withFileTypes: true })) {
26+
if (!entry.isDirectory()) {
27+
continue;
28+
}
29+
30+
const skillPath = path.join(rootPath, entry.name, 'SKILL.md');
31+
if (pathExists(skillPath)) {
32+
skillFiles.push({
33+
skillName: entry.name,
34+
skillPath,
35+
});
36+
}
37+
}
38+
39+
return skillFiles;
40+
}
41+
42+
console.log('Populating output directory...');
43+
44+
for (const relativeDir of [
45+
'agents/workflows',
46+
'claude/skills',
47+
'claude-plugin',
48+
'cursor/skills',
49+
'cursor-plugin',
50+
'opencode-plugin',
51+
'codex-plugin',
52+
'opencode/skills',
53+
'codex/skills',
54+
'gemini',
55+
'playwright',
56+
]) {
57+
ensureDirectory(path.join(outputDir, relativeDir));
58+
}
59+
60+
console.log('Populating Agents workflows...');
61+
for (const { skillName, skillPath } of listSkillFiles(skillsDir)) {
62+
copyFile(skillPath, path.join(outputDir, 'agents', 'workflows', `${skillName}.md`));
63+
}
64+
65+
console.log('Populating common skills...');
66+
const commonSkillFilename = '00-superplan-principles.md';
67+
for (const toolName of ['claude', 'cursor', 'opencode', 'codex']) {
68+
copyFile(
69+
path.join(skillsDir, commonSkillFilename),
70+
path.join(outputDir, toolName, 'skills', commonSkillFilename),
71+
);
72+
}
73+
74+
const officeHoursSourcePath = path.join(repoRoot, '.codex', 'skills', 'office-hours');
75+
if (pathExists(officeHoursSourcePath)) {
76+
fs.cpSync(
77+
officeHoursSourcePath,
78+
path.join(outputDir, 'codex', 'skills', 'office-hours'),
79+
{ recursive: true, force: true },
80+
);
81+
}
82+
83+
console.log('Fixing template paths...');
84+
const geminiTemplatePath = path.join(outputDir, 'gemini', 'GEMINI.md');
85+
if (pathExists(geminiTemplatePath)) {
86+
const geminiTemplate = fs.readFileSync(geminiTemplatePath, 'utf8');
87+
fs.writeFileSync(
88+
geminiTemplatePath,
89+
geminiTemplate.replace(/@\.\/*skills\//g, '@.superplan/skills/'),
90+
'utf8',
91+
);
92+
}
93+
94+
console.log('Output directory populated successfully.');

scripts/generate-outputs.sh

Lines changed: 2 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,5 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
# This script populates the output/ directory with agent-specific configuration files
5-
# and skills from the canonical source (the skills/ directory).
6-
7-
REPO_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
8-
OUTPUT_DIR="$REPO_ROOT/output"
9-
SKILLS_DIR="$REPO_ROOT/output/skills"
10-
11-
echo "Populating output directory..."
12-
13-
# 1. Clean up and ensure structure exists
14-
mkdir -p "$OUTPUT_DIR/agents/workflows"
15-
mkdir -p "$OUTPUT_DIR/claude/skills"
16-
mkdir -p "$OUTPUT_DIR/claude-plugin"
17-
mkdir -p "$OUTPUT_DIR/cursor/skills"
18-
mkdir -p "$OUTPUT_DIR/cursor-plugin"
19-
mkdir -p "$OUTPUT_DIR/opencode-plugin"
20-
mkdir -p "$OUTPUT_DIR/codex-plugin"
21-
mkdir -p "$OUTPUT_DIR/opencode/skills"
22-
mkdir -p "$OUTPUT_DIR/codex/skills"
23-
mkdir -p "$OUTPUT_DIR/gemini"
24-
mkdir -p "$OUTPUT_DIR/playwright"
25-
26-
# 2. Populate Gemini/Antigravity (Agents workflows)
27-
# Each SKILL.md in a subfolder of skills/ becomes a separately named file
28-
echo "Populating Agents workflows..."
29-
find "$SKILLS_DIR" -maxdepth 2 -name "SKILL.md" | while read -r skill_path; do
30-
skill_name=$(basename "$(dirname "$skill_path")")
31-
cp "$skill_path" "$OUTPUT_DIR/agents/workflows/$skill_name.md"
32-
done
33-
34-
# 3. Populate common skills for other tools
35-
# For now, this is just 00-superplan-principles.md
36-
echo "Populating common skills..."
37-
COMMON_SKILLS="00-superplan-principles.md"
38-
for tool in claude cursor opencode codex; do
39-
cp "$SKILLS_DIR/$COMMON_SKILLS" "$OUTPUT_DIR/$tool/skills/"
40-
done
41-
42-
# 4. Handle tool-specific skill subdirectories
43-
if [ -d "$REPO_ROOT/.codex/skills/office-hours" ]; then
44-
cp -r "$REPO_ROOT/.codex/skills/office-hours" "$OUTPUT_DIR/codex/skills/"
45-
fi
46-
47-
# 5. Fix template paths
48-
echo "Fixing template paths..."
49-
if [ -f "$OUTPUT_DIR/gemini/GEMINI.md" ]; then
50-
sed 's|@./skills/|@.superplan/skills/|g' "$OUTPUT_DIR/gemini/GEMINI.md" > "$OUTPUT_DIR/gemini/GEMINI.md.tmp"
51-
mv "$OUTPUT_DIR/gemini/GEMINI.md.tmp" "$OUTPUT_DIR/gemini/GEMINI.md"
52-
fi
53-
54-
echo "Output directory populated successfully."
4+
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
5+
node "$SCRIPT_DIR/generate-outputs.js"

0 commit comments

Comments
 (0)