react-doctor 0.0.40 → 0.0.41

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/dist/browser.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { _ as ScoreResult, a as diagnoseBrowser, c as diagnoseCore, d as diagnose, f as calculateScore, g as ReactDoctorConfig, h as ProjectInfo, i as DiagnoseBrowserInput, l as BrowserDiagnoseInput, m as Diagnostic, n as ProcessBrowserDiagnosticsResult, o as DiagnoseCoreOptions, p as calculateScoreLocally, r as processBrowserDiagnostics, s as DiagnoseCoreResult, t as ProcessBrowserDiagnosticsInput, u as BrowserDiagnoseResult } from "./process-browser-diagnostics-Cahx3_oy.js";
1
+ import { _ as ScoreResult, a as processBrowserDiagnostics, c as diagnoseCore, d as diagnose, f as calculateScore, g as ReactDoctorConfig, h as ProjectInfo, i as ProcessBrowserDiagnosticsResult, l as BrowserDiagnoseInput, m as Diagnostic, n as diagnoseBrowser, o as DiagnoseCoreOptions, p as calculateScoreLocally, r as ProcessBrowserDiagnosticsInput, s as DiagnoseCoreResult, t as DiagnoseBrowserInput, u as BrowserDiagnoseResult } from "./diagnose-browser-B17IqMa3.js";
2
2
  export { type BrowserDiagnoseInput, type BrowserDiagnoseResult, type DiagnoseBrowserInput, type DiagnoseCoreOptions, type DiagnoseCoreResult, type Diagnostic, type ProcessBrowserDiagnosticsInput, type ProcessBrowserDiagnosticsResult, type ProjectInfo, type ReactDoctorConfig, type ScoreResult, calculateScore, calculateScoreLocally, diagnose, diagnoseBrowser, diagnoseCore, processBrowserDiagnostics };
package/dist/cli.js CHANGED
@@ -15,6 +15,7 @@ import { main } from "knip";
15
15
  import { createOptions } from "knip/session";
16
16
 
17
17
  //#region src/utils/detect-agents.ts
18
+ const AGENTS_SKILL_DIR = ".agents/skills";
18
19
  const SUPPORTED_AGENTS = {
19
20
  claude: {
20
21
  binaries: ["claude"],
@@ -24,37 +25,37 @@ const SUPPORTED_AGENTS = {
24
25
  codex: {
25
26
  binaries: ["codex"],
26
27
  displayName: "Codex",
27
- skillDir: ".codex/skills"
28
+ skillDir: AGENTS_SKILL_DIR
28
29
  },
29
30
  copilot: {
30
31
  binaries: ["copilot"],
31
32
  displayName: "GitHub Copilot",
32
- skillDir: ".github/copilot/skills"
33
+ skillDir: AGENTS_SKILL_DIR
33
34
  },
34
35
  gemini: {
35
36
  binaries: ["gemini"],
36
37
  displayName: "Gemini CLI",
37
- skillDir: ".gemini/skills"
38
+ skillDir: AGENTS_SKILL_DIR
38
39
  },
39
40
  cursor: {
40
41
  binaries: ["cursor", "agent"],
41
42
  displayName: "Cursor",
42
- skillDir: ".cursor/skills"
43
+ skillDir: AGENTS_SKILL_DIR
43
44
  },
44
45
  opencode: {
45
46
  binaries: ["opencode"],
46
47
  displayName: "OpenCode",
47
- skillDir: ".opencode/skills"
48
+ skillDir: AGENTS_SKILL_DIR
48
49
  },
49
50
  droid: {
50
51
  binaries: ["droid"],
51
52
  displayName: "Factory Droid",
52
- skillDir: ".droid/skills"
53
+ skillDir: ".factory/skills"
53
54
  },
54
55
  pi: {
55
56
  binaries: ["pi", "omegon"],
56
57
  displayName: "Pi",
57
- skillDir: ".pi/skills"
58
+ skillDir: AGENTS_SKILL_DIR
58
59
  }
59
60
  };
60
61
  const ALL_SUPPORTED_AGENTS = Object.keys(SUPPORTED_AGENTS);
@@ -87,8 +88,9 @@ const highlighter = {
87
88
 
88
89
  //#endregion
89
90
  //#region src/utils/install-skill-for-agent.ts
90
- const installSkillForAgent = (projectRoot, agent, skillSourceDirectory, skillName) => {
91
+ const installSkillForAgent = (projectRoot, agent, skillSourceDirectory, skillName, alreadyInstalledDirectories) => {
91
92
  const installedSkillDirectory = path.join(projectRoot, toSkillDir(agent), skillName);
93
+ if (alreadyInstalledDirectories?.has(installedSkillDirectory)) return installedSkillDirectory;
92
94
  rmSync(installedSkillDirectory, {
93
95
  recursive: true,
94
96
  force: true
@@ -271,7 +273,11 @@ const runInstallSkill = async (options = {}) => {
271
273
  })).agents ?? [];
272
274
  if (selectedAgents.length === 0) return;
273
275
  const installSpinner = spinner(`Installing ${SKILL_NAME} skill...`).start();
274
- for (const agent of selectedAgents) installSkillForAgent(projectRoot, agent, sourceDir, SKILL_NAME);
276
+ const installedDirectories = /* @__PURE__ */ new Set();
277
+ for (const agent of selectedAgents) {
278
+ const installedDirectory = installSkillForAgent(projectRoot, agent, sourceDir, SKILL_NAME, installedDirectories);
279
+ installedDirectories.add(installedDirectory);
280
+ }
275
281
  installSpinner.succeed(`${SKILL_NAME} skill installed for ${selectedAgents.map(toDisplayName).join(", ")}.`);
276
282
  };
277
283
 
@@ -2565,7 +2571,7 @@ const promptProjectSelection = async (workspacePackages, rootDirectory) => {
2565
2571
 
2566
2572
  //#endregion
2567
2573
  //#region src/cli.ts
2568
- const VERSION = "0.0.40";
2574
+ const VERSION = "0.0.41";
2569
2575
  const VALID_FAIL_ON_LEVELS = new Set([
2570
2576
  "error",
2571
2577
  "warning",