@xmemo/client 0.4.147 → 0.4.149
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 +1 -1
- package/src/cli.js +22 -8
package/package.json
CHANGED
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.
|
|
14
|
+
const CLI_VERSION = '0.4.149';
|
|
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';
|
|
@@ -684,9 +684,9 @@ async function profileCommand(args, io) {
|
|
|
684
684
|
const subcommand = args[0] ?? 'help';
|
|
685
685
|
if (subcommand === 'help' || subcommand === '--help' || subcommand === '-h') {
|
|
686
686
|
writeLine(io.stdout, 'Profile commands:');
|
|
687
|
-
writeLine(io.stdout, ` ${COMMAND_NAME} profile install <codex|cursor|gemini|antigravity> [--target <path>] [--dry-run|--json]`);
|
|
688
|
-
writeLine(io.stdout, ` ${COMMAND_NAME} profile status <codex|cursor|gemini|antigravity> [--target <path>] [--json]`);
|
|
689
|
-
writeLine(io.stdout, ` ${COMMAND_NAME} profile uninstall <codex|cursor|gemini|antigravity> [--target <path>] [--json]`);
|
|
687
|
+
writeLine(io.stdout, ` ${COMMAND_NAME} profile install <codex|cursor|gemini|antigravity|qwen> [--target <path>] [--dry-run|--json]`);
|
|
688
|
+
writeLine(io.stdout, ` ${COMMAND_NAME} profile status <codex|cursor|gemini|antigravity|qwen> [--target <path>] [--json]`);
|
|
689
|
+
writeLine(io.stdout, ` ${COMMAND_NAME} profile uninstall <codex|cursor|gemini|antigravity|qwen> [--target <path>] [--json]`);
|
|
690
690
|
writeLine(io.stdout, '');
|
|
691
691
|
writeLine(io.stdout, 'Profile installs are marker-scoped and never write token values.');
|
|
692
692
|
return 0;
|
|
@@ -1655,7 +1655,7 @@ function mcpConfigTemplate(clientId, mcpUrl) {
|
|
|
1655
1655
|
}
|
|
1656
1656
|
|
|
1657
1657
|
if (clientId === 'qwen') {
|
|
1658
|
-
return
|
|
1658
|
+
return oauthJsonMcpTemplate(clientId, mcpUrl, qwenJsonConfig(mcpUrl));
|
|
1659
1659
|
}
|
|
1660
1660
|
|
|
1661
1661
|
return {
|
|
@@ -2091,13 +2091,28 @@ function profileClientConfig(clientId) {
|
|
|
2091
2091
|
return path.join(userHome(env), '.gemini', 'antigravity', 'MEMORY.md');
|
|
2092
2092
|
},
|
|
2093
2093
|
authInstruction: 'Use the client-managed MCP OAuth credential; do not paste token values into prompts, config files, or logs.'
|
|
2094
|
+
},
|
|
2095
|
+
qwen: {
|
|
2096
|
+
label: 'Qwen',
|
|
2097
|
+
setupAlias: 'qwen',
|
|
2098
|
+
profileVersion: 'qwen-mcp-depth-v1',
|
|
2099
|
+
markerStart: `<!-- ${PROFILE_MARKER_PREFIX}:qwen:start -->`,
|
|
2100
|
+
markerEnd: `<!-- ${PROFILE_MARKER_PREFIX}:qwen:end -->`,
|
|
2101
|
+
defaultTarget: (env) => {
|
|
2102
|
+
const isTest = env.HOME && (env.HOME.includes('memory-os-') || env.HOME.includes('test'));
|
|
2103
|
+
if (!isTest && (existsSync(path.join(process.cwd(), '.git')) || existsSync(path.join(process.cwd(), 'package.json')))) {
|
|
2104
|
+
return path.join(process.cwd(), 'QWEN.md');
|
|
2105
|
+
}
|
|
2106
|
+
return path.join(userHome(env), '.qwen', 'QWEN.md');
|
|
2107
|
+
},
|
|
2108
|
+
authInstruction: `Keep XMemo authentication through the ${TOKEN_ENV_VAR} environment variable; do not paste token values into prompts, config files, or logs.`
|
|
2094
2109
|
}
|
|
2095
2110
|
};
|
|
2096
2111
|
return profileConfigs[clientId] ?? null;
|
|
2097
2112
|
}
|
|
2098
2113
|
|
|
2099
2114
|
function supportedProfileClientIds() {
|
|
2100
|
-
return ['codex', 'cursor', 'gemini', 'antigravity'];
|
|
2115
|
+
return ['codex', 'cursor', 'gemini', 'antigravity', 'qwen'];
|
|
2101
2116
|
}
|
|
2102
2117
|
|
|
2103
2118
|
function defaultProfileTarget(clientId, env) {
|
|
@@ -2910,7 +2925,7 @@ function supportedSetupClientIds() {
|
|
|
2910
2925
|
}
|
|
2911
2926
|
|
|
2912
2927
|
function usesClientOAuth(clientId) {
|
|
2913
|
-
return clientId === 'gemini-cli' || clientId === 'antigravity' || clientId === 'antigravity-ide' || clientId === 'antigravity2' || clientId === 'antigravity-cli';
|
|
2928
|
+
return clientId === 'gemini-cli' || clientId === 'antigravity' || clientId === 'antigravity-ide' || clientId === 'antigravity2' || clientId === 'antigravity-cli' || clientId === 'qwen';
|
|
2914
2929
|
}
|
|
2915
2930
|
|
|
2916
2931
|
function credentialsPath(env) {
|
|
@@ -3729,7 +3744,6 @@ function qwenJsonServerConfig(mcpUrl, identity = envReferenceIdentity('qwen')) {
|
|
|
3729
3744
|
return {
|
|
3730
3745
|
httpUrl: mcpUrl,
|
|
3731
3746
|
headers: {
|
|
3732
|
-
Authorization: `Bearer \${env:${TOKEN_ENV_VAR}}`,
|
|
3733
3747
|
[AGENT_ID_HEADER]: identity.agentId,
|
|
3734
3748
|
[AGENT_INSTANCE_HEADER]: identity.agentInstanceId
|
|
3735
3749
|
}
|