@mthines/reaper-mcp 0.71.0-beta.83.1 → 0.71.0-beta.83.2
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/main.js +40 -0
- package/package.json +1 -1
package/main.js
CHANGED
|
@@ -4232,6 +4232,40 @@ function ensureBridgeAutostart(startup) {
|
|
|
4232
4232
|
}
|
|
4233
4233
|
return { text: text7, changed: text7 !== startup };
|
|
4234
4234
|
}
|
|
4235
|
+
function readExtState(ini, section, key) {
|
|
4236
|
+
let inSection = false;
|
|
4237
|
+
for (const line of ini.split(/\r?\n/)) {
|
|
4238
|
+
const header = /^\s*\[(.*)\]\s*$/.exec(line);
|
|
4239
|
+
if (header) {
|
|
4240
|
+
inSection = header[1] === section;
|
|
4241
|
+
} else if (inSection) {
|
|
4242
|
+
const eq = line.indexOf("=");
|
|
4243
|
+
if (eq !== -1 && line.slice(0, eq).trim() === key) return line.slice(eq + 1).trim();
|
|
4244
|
+
}
|
|
4245
|
+
}
|
|
4246
|
+
return void 0;
|
|
4247
|
+
}
|
|
4248
|
+
function autostartCheck(startup, extstate, reaperRunning) {
|
|
4249
|
+
const label = "Start with REAPER";
|
|
4250
|
+
if (startup === null || !startup.includes(AUTOSTART_MARKER)) {
|
|
4251
|
+
return {
|
|
4252
|
+
label,
|
|
4253
|
+
status: "warn",
|
|
4254
|
+
detail: "Not in REAPER's Scripts/__startup.lua: run mcp_bridge.lua by hand in each REAPER session",
|
|
4255
|
+
fix: "reaper-mcp setup"
|
|
4256
|
+
};
|
|
4257
|
+
}
|
|
4258
|
+
const saved = reaperRunning ? " (as REAPER last saved it)" : "";
|
|
4259
|
+
if (extstate !== null && readExtState(extstate, "MCPBridge", "cfg_autostart") === "0") {
|
|
4260
|
+
return {
|
|
4261
|
+
label,
|
|
4262
|
+
status: "info",
|
|
4263
|
+
detail: `Off in the bridge window${saved}: run mcp_bridge.lua by hand in each REAPER session`,
|
|
4264
|
+
fix: "turn it back on in the bridge window: Settings \u2192 Start with REAPER"
|
|
4265
|
+
};
|
|
4266
|
+
}
|
|
4267
|
+
return { label, status: "ok", detail: `On \xB7 REAPER's startup script runs the bridge at launch${saved}` };
|
|
4268
|
+
}
|
|
4235
4269
|
var MCP_TOOL_NAMES = [
|
|
4236
4270
|
// project
|
|
4237
4271
|
"get_project_info",
|
|
@@ -9144,6 +9178,12 @@ async function doctor() {
|
|
|
9144
9178
|
core2.push(
|
|
9145
9179
|
bridgeRunning ? { label: "Lua bridge", status: "ok", detail: "Connected" } : { label: "Lua bridge", status: "fail", detail: "Not detected", fix: "reaper-mcp setup, then run mcp_bridge.lua in REAPER" }
|
|
9146
9180
|
);
|
|
9181
|
+
const readIfExists = (path) => existsSync7(path) ? readFileSync5(path, "utf-8") : null;
|
|
9182
|
+
core2.push(autostartCheck(
|
|
9183
|
+
readIfExists(join12(getReaperScriptsPath(), "__startup.lua")),
|
|
9184
|
+
readIfExists(join12(getReaperResourcePath(), "reaper-extstate.ini")),
|
|
9185
|
+
await isReaperRunning()
|
|
9186
|
+
));
|
|
9147
9187
|
const globalClaudeDir = join12(homedir8(), ".claude");
|
|
9148
9188
|
const localSkills = existsSync7(join12(process.cwd(), ".claude", "skills", "mixer", "SKILL.md"));
|
|
9149
9189
|
const globalSkills = existsSync7(join12(globalClaudeDir, "skills", "mixer", "SKILL.md"));
|
package/package.json
CHANGED