Skip to content

Commit c281c9d

Browse files
oalanicolasclaude
andcommitted
fix: correct relative paths in consolidated modules
After moving src/ to packages/installer/src/, some relative paths needed to be updated from 2 levels (../../) to 4 levels (../../../../) to correctly reference project root files and directories. Fixed paths in: - aios-core-installer.js: .aios-core source path - feedback.js: package.json path - ide-config-generator.js: templates, agents, and rules paths Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 0046843 commit c281c9d

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

packages/installer/src/installer/aios-core-installer.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ const ora = require('ora');
1717
* @returns {string} Absolute path to .aios-core source
1818
*/
1919
function getAiosCoreSourcePath() {
20-
// Navigate from src/installer/ to project root/.aios-core
21-
return path.join(__dirname, '..', '..', '.aios-core');
20+
// Navigate from packages/installer/src/installer/ to project root/.aios-core
21+
return path.join(__dirname, '..', '..', '..', '..', '.aios-core');
2222
}
2323

2424
/**

packages/installer/src/wizard/feedback.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ function showWelcome() {
139139
const fs = require('fs');
140140
let version = '2.1.0';
141141
try {
142-
const pkgPath = path.join(__dirname, '..', '..', 'package.json');
142+
const pkgPath = path.join(__dirname, '..', '..', '..', '..', 'package.json');
143143
const pkg = JSON.parse(fs.readFileSync(pkgPath, 'utf8'));
144144
version = pkg.version || version;
145145
} catch (_e) {

packages/installer/src/wizard/ide-config-generator.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ function generateTemplateVariables(wizardState) {
185185
*/
186186
async function copyAgentFiles(projectRoot, agentFolder, ideConfig = null) {
187187
// v2.1: Agents are in development/agents/ (not root agents/)
188-
const sourceDir = path.join(__dirname, '..', '..', '.aios-core', 'development', 'agents');
188+
const sourceDir = path.join(__dirname, '..', '..', '..', '..', '.aios-core', 'development', 'agents');
189189
const targetDir = path.join(projectRoot, agentFolder);
190190
const copiedFiles = [];
191191

@@ -241,7 +241,7 @@ async function copyAgentFiles(projectRoot, agentFolder, ideConfig = null) {
241241
* @returns {Promise<string[]>} List of copied files
242242
*/
243243
async function copyClaudeRulesFolder(projectRoot) {
244-
const sourceDir = path.join(__dirname, '..', '..', '.claude', 'rules');
244+
const sourceDir = path.join(__dirname, '..', '..', '..', '..', '.claude', 'rules');
245245
const targetDir = path.join(projectRoot, '.claude', 'rules');
246246
const copiedFiles = [];
247247

@@ -413,7 +413,7 @@ async function generateIDEConfigs(selectedIDEs, wizardState, options = {}) {
413413
}
414414

415415
// Load template from .aios-core/product/templates/
416-
const templatePath = path.join(__dirname, '..', '..', '.aios-core', 'product', 'templates', ide.template);
416+
const templatePath = path.join(__dirname, '..', '..', '..', '..', '.aios-core', 'product', 'templates', ide.template);
417417

418418
if (!await fs.pathExists(templatePath)) {
419419
throw new Error(`Template file not found: ${ide.template}`);

0 commit comments

Comments
 (0)