@ajsmonty/adobe-mcp 1.1.1 → 1.1.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/README.md +2 -0
- package/core/bridge.mjs +2 -3
- package/core/workspace.mjs +35 -0
- package/knowledge/knowledge.mjs +1 -2
- package/knowledge/lessons.jsonl +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -45,6 +45,8 @@ wind loops and kinetic typography rigs (AE), one-call vertical Auto Reframe (Pre
|
|
|
45
45
|
2. Download the latest `adobe-mcp-x.y.z.mcpb` from [Releases](https://github.com/AJSMonty/adobe-mcp/releases) and **double-click it** (or drag it onto Claude Desktop → Settings → Extensions). Claude Desktop bundles its own Node runtime — nothing else to install.
|
|
46
46
|
3. Use it. The first tool call for each app triggers a one-time macOS **Automation** permission prompt — click Allow.
|
|
47
47
|
|
|
48
|
+
**Upgrading?** Remove the old version first (Settings → Extensions → Adobe Creative Cloud → Uninstall), then install the new `.mcpb` — in-place installs over an existing version can leave stale files behind while reporting the new version number.
|
|
49
|
+
|
|
48
50
|
### Option B — any MCP client via npm
|
|
49
51
|
|
|
50
52
|
Requires Node 18+ installed system-wide ([nodejs.org](https://nodejs.org) installer or `brew install node` — note GUI apps often cannot see nvm-managed installs). No clone, no `npm install`: every client config below just runs
|
package/core/bridge.mjs
CHANGED
|
@@ -7,14 +7,13 @@ import os from "node:os";
|
|
|
7
7
|
import path from "node:path";
|
|
8
8
|
import { fileURLToPath } from "node:url";
|
|
9
9
|
import { logError, matchError, hintBlock } from "../knowledge/knowledge.mjs";
|
|
10
|
+
import { WORKSPACE } from "./workspace.mjs";
|
|
10
11
|
|
|
11
12
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
12
13
|
const HARNESS = fs.readFileSync(path.join(__dirname, "harness.jsx"), "utf8");
|
|
13
14
|
|
|
14
|
-
export
|
|
15
|
-
process.env.ADOBE_MCP_WORKSPACE || path.join(os.homedir(), "AdobeMCP");
|
|
15
|
+
export { WORKSPACE };
|
|
16
16
|
export const PPRO_BRIDGE_DIR = path.join(WORKSPACE, "ppro-bridge");
|
|
17
|
-
fs.mkdirSync(WORKSPACE, { recursive: true });
|
|
18
17
|
fs.mkdirSync(PPRO_BRIDGE_DIR, { recursive: true });
|
|
19
18
|
|
|
20
19
|
// ---------------------------------------------------------------------------
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
// Workspace resolution — shared by the bridge and the knowledge system.
|
|
2
|
+
//
|
|
3
|
+
// Hardened against host quirks: some MCP hosts pass manifest placeholders through
|
|
4
|
+
// unexpanded (e.g. Claude Desktop delivered ADOBE_MCP_WORKSPACE='${HOME}/AdobeMCP'
|
|
5
|
+
// literally, with cwd=/ — which crashed mkdir at module load). Rules:
|
|
6
|
+
// - expand a leading ${HOME} or ~
|
|
7
|
+
// - reject any value still containing ${...} or that is not absolute
|
|
8
|
+
// - if the directory cannot be created, fall back to ~/AdobeMCP rather than dying
|
|
9
|
+
import fs from "node:fs";
|
|
10
|
+
import os from "node:os";
|
|
11
|
+
import path from "node:path";
|
|
12
|
+
|
|
13
|
+
function resolveWorkspace() {
|
|
14
|
+
const fallback = path.join(os.homedir(), "AdobeMCP");
|
|
15
|
+
let w = process.env.ADOBE_MCP_WORKSPACE;
|
|
16
|
+
if (w && w.trim()) {
|
|
17
|
+
w = w.trim().replace(/^\$\{HOME\}/, os.homedir()).replace(/^~(?=\/|$)/, os.homedir());
|
|
18
|
+
if (!w.includes("${") && path.isAbsolute(w)) {
|
|
19
|
+
try {
|
|
20
|
+
fs.mkdirSync(w, { recursive: true });
|
|
21
|
+
return w;
|
|
22
|
+
} catch {
|
|
23
|
+
console.error(`adobe-mcp: cannot create workspace "${w}", falling back to ${fallback}`);
|
|
24
|
+
}
|
|
25
|
+
} else {
|
|
26
|
+
console.error(
|
|
27
|
+
`adobe-mcp: ignoring invalid ADOBE_MCP_WORKSPACE "${process.env.ADOBE_MCP_WORKSPACE}" (unexpanded placeholder or relative path), using ${fallback}`
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
fs.mkdirSync(fallback, { recursive: true });
|
|
32
|
+
return fallback;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export const WORKSPACE = resolveWorkspace();
|
package/knowledge/knowledge.mjs
CHANGED
|
@@ -15,10 +15,9 @@ import fs from "node:fs";
|
|
|
15
15
|
import os from "node:os";
|
|
16
16
|
import path from "node:path";
|
|
17
17
|
import { fileURLToPath } from "node:url";
|
|
18
|
+
import { WORKSPACE } from "../core/workspace.mjs";
|
|
18
19
|
|
|
19
20
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
20
|
-
const WORKSPACE =
|
|
21
|
-
process.env.ADOBE_MCP_WORKSPACE || path.join(os.homedir(), "AdobeMCP");
|
|
22
21
|
const SEED_PATH = path.join(__dirname, "lessons.jsonl");
|
|
23
22
|
const LEARNED_PATH = path.join(WORKSPACE, "learned.jsonl");
|
|
24
23
|
const ERROR_LOG = path.join(WORKSPACE, "error-log.jsonl");
|
package/knowledge/lessons.jsonl
CHANGED
|
@@ -26,3 +26,4 @@
|
|
|
26
26
|
{"id":"any-pexels-sourcing","app":"any","title":"Pexels direct-download pattern for stock sourcing","match":[],"lesson":"https://images.pexels.com/photos/{id}/pexels-photo-{id}.jpeg?auto=compress&cs=tinysrgb&w=1600 downloads directly (free license, no attribution). Very old photo IDs can 404 (came back 27 bytes) — check file size/type after curl and keep an alternate ID. Choose isolated, high-contrast subjects when the image will be edge-extracted or cut out.","added":"2026-07-14","source":"session"}
|
|
27
27
|
{"id":"any-es3","app":"any","title":"ExtendScript is ES3","match":["json is undefined","is not a function"],"lesson":"No JSON object, let/const, arrow functions, template literals, Array.map/filter/forEach inside the apps. Use var, string concat, and index loops. AE collections are 1-indexed (comp.layer(1) is the top layer); PS artLayers are 0-indexed. The MCP harness JSON-serializes your return value for you.","added":"2026-07-14","source":"session"}
|
|
28
28
|
{"id":"ch-puppet-taxonomy","app":"ch","title":"Extra layers ride along in CH puppet groups","match":[],"lesson":"Character Animator auto-rigs from the layer-name taxonomy (+Character root, Head/Body groups, 14 visemes, Blink layers). Extra non-taxonomy layers (logos, badges) placed INSIDE a group (e.g. Body) simply ride with that group — safe way to add art to a rigged puppet. Remove stray empty layers at root before import.","added":"2026-07-14","source":"session"}
|
|
29
|
+
{"id":"any-host-env-placeholders","app":"any","title":"MCP hosts may pass manifest placeholders unexpanded","match":["no such file or directory, mkdir"],"lesson":"Claude Desktop delivered the .mcpb manifest's ${HOME} user_config default literally as ADOBE_MCP_WORKSPACE='${HOME}/AdobeMCP' with cwd=/, crashing workspace mkdir at module load ('Server disconnected', nothing on stderr). Never trust env-provided paths: expand ${HOME}/~ yourself, reject values still containing ${...} or relative paths, and fall back to a safe default instead of dying (core/workspace.mjs).","added":"2026-07-15","source":"session"}
|