rtexit-method 0.1.2 → 0.1.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rtexit-method",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "RTExit - AI-assisted Red Team methodology installer",
5
5
  "license": "MIT",
6
6
  "author": "Exit Code",
@@ -21,7 +21,7 @@
21
21
  },
22
22
  "dependencies": {
23
23
  "@clack/prompts": "^1.4.0",
24
- "commander": "^14.0.0"
24
+ "commander": "^14.0.0"
25
25
  },
26
26
  "engines": {
27
27
  "node": ">=20.12.0"
@@ -20,7 +20,8 @@ async function installCommand(options = {}) {
20
20
 
21
21
  const targetRoot = resolveTargetRoot(answers.targetDirectory);
22
22
 
23
- await copyPackagedAssets({ repoRoot, targetRoot });
23
+ const ides = answers.ides && answers.ides.length ? answers.ides : ['agents'];
24
+ await copyPackagedAssets({ repoRoot, targetRoot, ides });
24
25
  await writeUserConfig({
25
26
  targetRoot,
26
27
  answers: {
@@ -29,7 +30,13 @@ async function installCommand(options = {}) {
29
30
  },
30
31
  });
31
32
 
33
+ const ideFolders = ides.map((ide) => {
34
+ const map = { agents: '.agents/skills', claude: '.claude/skills', trae: '.trae/skills', codex: '.codex/skills' };
35
+ return map[ide] || `.${ide}/skills`;
36
+ });
37
+
32
38
  io.log('RTExit installed successfully.');
39
+ io.log(`Skills installed into: ${ideFolders.join(', ')}`);
33
40
  io.log('Next steps:');
34
41
  io.log('1. Open _rtexit/config.user.toml and complete client/project details');
35
42
  io.log('2. Open your AI IDE in this project');
@@ -1,15 +1,24 @@
1
- function getInstallEntries() {
1
+ const IDE_SKILL_FOLDERS = {
2
+ agents: '.agents/skills',
3
+ claude: '.claude/skills',
4
+ trae: '.trae/skills',
5
+ codex: '.codex/skills',
6
+ };
7
+
8
+ function getInstallEntries(ides = ['agents']) {
9
+ const skillEntries = ides.map((ide) => ({
10
+ type: 'glob-dir-prefix',
11
+ base: 'packaged-assets/.agents/skills',
12
+ targetBase: IDE_SKILL_FOLDERS[ide] || `.${ide}/skills`,
13
+ prefix: 'rt-',
14
+ }));
15
+
2
16
  return [
3
- {
4
- type: 'glob-dir-prefix',
5
- base: 'packaged-assets/.agents/skills',
6
- targetBase: '.agents/skills',
7
- prefix: 'rt-'
8
- },
9
- { type: 'path', value: 'packaged-assets/_rtexit', target: '_rtexit' },
10
- { type: 'path', value: 'packaged-assets/templates', target: 'templates' },
11
- { type: 'path', value: 'packaged-assets/resources', target: 'resources' },
12
- { type: 'path', value: 'packaged-assets/RTEXIT.md', target: 'RTEXIT.md' }
17
+ ...skillEntries,
18
+ { type: 'path', value: 'packaged-assets/_rtexit', target: '_rtexit' },
19
+ { type: 'path', value: 'packaged-assets/templates', target: 'templates' },
20
+ { type: 'path', value: 'packaged-assets/resources', target: 'resources' },
21
+ { type: 'path', value: 'packaged-assets/RTEXIT.md', target: 'RTEXIT.md' },
13
22
  ];
14
23
  }
15
24
 
@@ -17,8 +17,8 @@ function copyRecursive(source, target) {
17
17
  fs.copyFileSync(source, target);
18
18
  }
19
19
 
20
- async function copyPackagedAssets({ repoRoot, targetRoot }) {
21
- for (const entry of getInstallEntries()) {
20
+ async function copyPackagedAssets({ repoRoot, targetRoot, ides }) {
21
+ for (const entry of getInstallEntries(ides)) {
22
22
  if (entry.type === 'path') {
23
23
  const sourcePath = path.join(repoRoot, entry.value);
24
24
  const targetPath = path.join(targetRoot, entry.target || entry.value);
@@ -22,12 +22,24 @@ async function askInstallQuestions({ cwd }) {
22
22
  ],
23
23
  });
24
24
 
25
+ const ides = await prompts.multiselect({
26
+ message: 'Which AI IDEs are you using? (space to select, enter to confirm)',
27
+ options: [
28
+ { value: 'agents', label: 'Cursor / Windsurf / VS Code (.agents/skills/)' },
29
+ { value: 'claude', label: 'Claude Code (.claude/skills/)' },
30
+ { value: 'trae', label: 'Trae (.trae/skills/)' },
31
+ { value: 'codex', label: 'Codex / OpenAI (.codex/skills/)' },
32
+ ],
33
+ initialValues: ['agents'],
34
+ required: true,
35
+ });
36
+
25
37
  const confirmed = await prompts.confirm({
26
38
  message: `Install RTExit into ${targetDirectory}?`,
27
39
  initialValue: true,
28
40
  });
29
41
 
30
- return { targetDirectory, language, document_output_language, confirmed };
42
+ return { targetDirectory, language, document_output_language, ides, confirmed };
31
43
  }
32
44
 
33
45
  module.exports = { askInstallQuestions };