dsh-reference-anything 0.4.3 → 0.4.4

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/lib/wire.js CHANGED
@@ -9,12 +9,18 @@ export const LOCAL_AGENT_LABEL = {
9
9
  openclaw: 'OpenClaw', kimi: 'Kimi', grokbuild: 'Grok Build', hermes: 'Hermes', 'gemini-cli': 'Gemini CLI',
10
10
  pi: 'Pi', opencode: 'opencode', mimocode: 'mimocode', zcode: 'zcode',
11
11
  };
12
- export const pickerSourceSchema = z.enum(['commands', 'skills', 'files', 'sessions', 'agents', 'conversations', 'drives']);
12
+ export const pickerSourceSchema = z.enum(['commands', 'skills', 'files', 'sessions', 'agents', 'conversations', 'drives', 'plugins']);
13
+ export const pickerSortSchema = z.enum(['name', 'updated']);
13
14
  const pickerSourceSettingsSchema = z.object({
14
15
  enabled: z.boolean(),
15
16
  order: z.number().int().min(0).max(100),
16
17
  limit: z.number().int().min(1).max(50),
17
18
  maxCandidates: z.number().int().min(1).max(50).default(50),
19
+ sort: pickerSortSchema.default('updated'),
20
+ /** Optional extra token for `@token:` scoped searches. */
21
+ shortcut: z.string().regex(/^[^@:\s/]*(,[^@:\s/]+)*$/u).max(32).default(''),
22
+ aliases: z.array(z.string().regex(/^[^@:\s/]+$/u).max(32)).optional(),
23
+ sourceAliases: z.record(z.string(), z.array(z.string().regex(/^[^@:\s/]+$/u).max(32))).optional(),
18
24
  });
19
25
  export const pickerSettingsSchema = z.object({
20
26
  displayMode: z.enum(['collapse', 'native-scroll']).default('collapse'),
@@ -27,23 +33,28 @@ export const pickerSettingsSchema = z.object({
27
33
  // a saved record that has `picker` but predates this key would fail the whole
28
34
  // parse without it, and the medium — every setting in it — would be rejected.
29
35
  // Any key added here from now on needs the same treatment.
30
- agents: pickerSourceSettingsSchema.default({ enabled: true, order: 25, limit: 6, maxCandidates: 50 }),
36
+ agents: pickerSourceSettingsSchema.default({ enabled: true, order: 25, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['agent', 'cc', 'claude-code', 'codex', 'cursor', 'gemini-cli', 'qoder', 'reasonix', 'openclaw', 'hermes', 'pi', 'grokbuild', 'grok-build', 'kimi-cli', 'kimi-code', 'opencode', 'mimocode', 'mimo', 'zcode'] }),
31
37
  conversations: pickerSourceSettingsSchema,
32
38
  // Defaulted for the same reason as `agents` above: it arrived later still.
33
- drives: pickerSourceSettingsSchema.default({ enabled: true, order: 35, limit: 6, maxCandidates: 50 }),
39
+ drives: pickerSourceSettingsSchema.default({ enabled: true, order: 35, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['drive'] }),
40
+ plugins: pickerSourceSettingsSchema.extend({
41
+ onlyLive: z.boolean().default(false),
42
+ showDeepSeek: z.boolean().default(true),
43
+ }).default({ enabled: true, order: 40, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['plugin'], onlyLive: false, showDeepSeek: true }),
34
44
  });
35
45
  export const inputRenderModeSchema = z.enum(['pill', 'raw-text']);
36
46
  /** Defaults used before the user saves the General section. */
37
47
  export function defaultPickerSettings() {
38
48
  return {
39
49
  displayMode: 'collapse',
40
- commands: { enabled: true, order: 0, limit: 6, maxCandidates: 50 },
41
- skills: { enabled: true, order: 5, limit: 6, maxCandidates: 50 },
42
- files: { enabled: true, order: 10, limit: 6, maxCandidates: 50 },
43
- sessions: { enabled: true, order: 20, limit: 6, maxCandidates: 50 },
44
- agents: { enabled: true, order: 25, limit: 6, maxCandidates: 50 },
45
- conversations: { enabled: true, order: 30, limit: 6, maxCandidates: 50 },
46
- drives: { enabled: true, order: 35, limit: 6, maxCandidates: 50 },
50
+ commands: { enabled: true, order: 0, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['command'] },
51
+ skills: { enabled: true, order: 5, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['skill'] },
52
+ files: { enabled: true, order: 10, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['file'] },
53
+ sessions: { enabled: true, order: 20, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['session'] },
54
+ agents: { enabled: true, order: 25, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['agent', 'cc', 'claude-code', 'codex', 'cursor', 'gemini-cli', 'qoder', 'reasonix', 'openclaw', 'hermes', 'pi', 'grokbuild', 'grok-build', 'kimi-cli', 'kimi-code', 'opencode', 'mimocode', 'mimo', 'zcode'] },
55
+ conversations: { enabled: true, order: 30, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['chat'] },
56
+ drives: { enabled: true, order: 35, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['drive'] },
57
+ plugins: { enabled: true, order: 40, limit: 6, maxCandidates: 50, sort: 'updated', shortcut: '', aliases: ['plugin'], onlyLive: false, showDeepSeek: true },
47
58
  };
48
59
  }
49
60
  /** Picker settings have a fixed schema, so explicit comparison is cheap and stable. */
@@ -53,7 +64,12 @@ export function samePickerSettings(left, right) {
53
64
  return pickerSourceSchema.options.every(key => left[key].enabled === right[key].enabled &&
54
65
  left[key].order === right[key].order &&
55
66
  left[key].limit === right[key].limit &&
56
- left[key].maxCandidates === right[key].maxCandidates);
67
+ left[key].maxCandidates === right[key].maxCandidates &&
68
+ left[key].sort === right[key].sort &&
69
+ left[key].shortcut === right[key].shortcut &&
70
+ JSON.stringify(left[key].aliases) === JSON.stringify(right[key].aliases) &&
71
+ JSON.stringify(left[key].sourceAliases) === JSON.stringify(right[key].sourceAliases) &&
72
+ (key !== 'plugins' || (left.plugins.onlyLive === right.plugins.onlyLive && left.plugins.showDeepSeek === right.plugins.showDeepSeek)));
57
73
  }
58
74
  export const settingsRecordSchema = z.object({
59
75
  opencliPath: z.string(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-reference-anything",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "description": "Reference files, sessions, commands, skills, and historical external AI chats from the DSH @ menu.",
5
5
  "icon": "./images/logo-icon.png",
6
6
  "license": "MIT",
@@ -187,6 +187,8 @@
187
187
  },
188
188
  "devDependencies": {
189
189
  "@deepseek-ai/cordis": "^4.0.1",
190
+ "@deepseek-ai/cordis-plugin-include": "1.0.9",
191
+ "@deepseek-ai/cordis-plugin-loader": "1.0.5",
190
192
  "@deepseek-ai/dsh-agent": "0.2.0-rc.2",
191
193
  "@deepseek-ai/dsh-api-remotes": "0.2.0-rc.2",
192
194
  "@deepseek-ai/dsh-api-session-controller": "0.2.0-rc.2",