@xmemo/client 0.4.154 → 0.4.155

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/cli.js +37 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xmemo/client",
3
- "version": "0.4.154",
3
+ "version": "0.4.155",
4
4
  "description": "Privacy-first CLI and MCP setup helper for XMemo.",
5
5
  "type": "module",
6
6
  "bin": {
package/src/cli.js CHANGED
@@ -11,7 +11,7 @@ const PACKAGE_NAME = '@xmemo/client';
11
11
  const FALLBACK_PACKAGE_NAME = '@yonro/xmemo-client';
12
12
  const COMMAND_NAME = 'xmemo';
13
13
  const LEGACY_COMMAND_NAME = 'memory-os';
14
- const CLI_VERSION = '0.4.154';
14
+ const CLI_VERSION = '0.4.155';
15
15
  const DEFAULT_SERVICE_URL = 'https://xmemo.dev';
16
16
  const TOKEN_ENV_VAR = 'XMEMO_KEY';
17
17
  const LEGACY_TOKEN_ENV_VAR = 'MEMORY_OS_MCP_TOKEN';
@@ -27,7 +27,9 @@ const CODEX_PROFILE_MARKER_END = '<!-- memory-os:codex-profile:end -->';
27
27
  const CLIENT_PROFILE_TARGETS = {
28
28
  cursor: '.cursor/rules/xmemo-memory.md',
29
29
  'gemini-cli': 'GEMINI.md',
30
- antigravity: 'GEMINI.md'
30
+ antigravity: 'GEMINI.md',
31
+ trae: '.trae/rules/xmemo-memory.md',
32
+ 'trae-solo': '.trae/rules/xmemo-memory.md'
31
33
  };
32
34
  const CLIENT_PROFILE_MARKER_START = '<!-- xmemo:profile:start -->';
33
35
  const CLIENT_PROFILE_MARKER_END = '<!-- xmemo:profile:end -->';
@@ -2167,13 +2169,45 @@ function profileClientConfig(clientId) {
2167
2169
  return path.join(userHome(env), '.config', 'opencode', 'AGENTS.md');
2168
2170
  },
2169
2171
  authInstruction: 'Use the client-managed MCP OAuth credential; do not paste token values into prompts, config files, or logs.'
2172
+ },
2173
+ trae: {
2174
+ label: 'Trae',
2175
+ setupAlias: 'trae',
2176
+ profileVersion: 'trae-mcp-depth-v1',
2177
+ requiredTokenEnv: TOKEN_ENV_VAR,
2178
+ markerStart: `<!-- ${PROFILE_MARKER_PREFIX}:trae:start -->`,
2179
+ markerEnd: `<!-- ${PROFILE_MARKER_PREFIX}:trae:end -->`,
2180
+ defaultTarget: (env) => {
2181
+ const isTest = env.HOME && (env.HOME.includes('memory-os-') || env.HOME.includes('test'));
2182
+ if (!isTest && (existsSync(path.join(process.cwd(), '.trae')) || existsSync(path.join(process.cwd(), '.git')) || existsSync(path.join(process.cwd(), 'package.json')))) {
2183
+ return path.join(process.cwd(), '.trae', 'rules', 'xmemo-memory.md');
2184
+ }
2185
+ return path.join(userHome(env), '.trae', 'memory-profile.md');
2186
+ },
2187
+ authInstruction: `Keep XMemo authentication through the ${TOKEN_ENV_VAR} environment variable; do not paste token values into prompts, config files, or logs.`
2188
+ },
2189
+ 'trae-solo': {
2190
+ label: 'Trae Solo',
2191
+ setupAlias: 'trae-solo',
2192
+ profileVersion: 'trae-solo-mcp-depth-v1',
2193
+ requiredTokenEnv: TOKEN_ENV_VAR,
2194
+ markerStart: `<!-- ${PROFILE_MARKER_PREFIX}:trae-solo:start -->`,
2195
+ markerEnd: `<!-- ${PROFILE_MARKER_PREFIX}:trae-solo:end -->`,
2196
+ defaultTarget: (env) => {
2197
+ const isTest = env.HOME && (env.HOME.includes('memory-os-') || env.HOME.includes('test'));
2198
+ if (!isTest && (existsSync(path.join(process.cwd(), '.trae')) || existsSync(path.join(process.cwd(), '.git')) || existsSync(path.join(process.cwd(), 'package.json')))) {
2199
+ return path.join(process.cwd(), '.trae', 'rules', 'xmemo-memory.md');
2200
+ }
2201
+ return path.join(userHome(env), '.trae', 'memory-profile.md');
2202
+ },
2203
+ authInstruction: `Keep XMemo authentication through the ${TOKEN_ENV_VAR} environment variable; do not paste token values into prompts, config files, or logs.`
2170
2204
  }
2171
2205
  };
2172
2206
  return profileConfigs[clientId] ?? null;
2173
2207
  }
2174
2208
 
2175
2209
  function supportedProfileClientIds() {
2176
- return ['codex', 'cursor', 'gemini', 'antigravity', 'qwen', 'opencode'];
2210
+ return ['codex', 'cursor', 'gemini', 'antigravity', 'qwen', 'opencode', 'trae', 'trae-solo'];
2177
2211
  }
2178
2212
 
2179
2213
  function defaultProfileTarget(clientId, env) {