dsh-git-worktree 0.11.0 → 0.12.0

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 (44) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/README.en.md +26 -19
  3. package/README.md +26 -19
  4. package/lib/adapters/git.js +45 -8
  5. package/lib/adapters/git.js.map +1 -1
  6. package/lib/adapters/project-skill-io.js +7 -1
  7. package/lib/adapters/project-skill-io.js.map +1 -1
  8. package/lib/adapters/project-skill-snapshot.d.ts +10 -0
  9. package/lib/adapters/project-skill-snapshot.js +182 -0
  10. package/lib/adapters/project-skill-snapshot.js.map +1 -0
  11. package/lib/adapters/project-skills.d.ts +18 -3
  12. package/lib/adapters/project-skills.js +102 -13
  13. package/lib/adapters/project-skills.js.map +1 -1
  14. package/lib/client/WorktreeCreateRow.js +14 -2
  15. package/lib/client/WorktreeCreateRow.js.map +1 -1
  16. package/lib/client/actions.d.ts +32 -1
  17. package/lib/client/actions.js +41 -0
  18. package/lib/client/actions.js.map +1 -1
  19. package/lib/client/index.d.ts +6 -1
  20. package/lib/client/index.js +11 -2
  21. package/lib/client/index.js.map +1 -1
  22. package/lib/client/target-console/TargetStatusAction.js +11 -9
  23. package/lib/client/target-console/TargetStatusAction.js.map +1 -1
  24. package/lib/client/workspace-desktop.d.ts +15 -0
  25. package/lib/client/workspace-desktop.js +95 -0
  26. package/lib/client/workspace-desktop.js.map +1 -0
  27. package/lib/client.js +255 -105
  28. package/lib/console-host/review-diff.js +9 -4
  29. package/lib/console-host/review-diff.js.map +1 -1
  30. package/lib/creation-failure.d.ts +6 -0
  31. package/lib/creation-failure.js +9 -0
  32. package/lib/creation-failure.js.map +1 -1
  33. package/lib/i18n/client-messages.d.ts +8 -0
  34. package/lib/i18n/client-messages.js +3 -1
  35. package/lib/i18n/client-messages.js.map +1 -1
  36. package/lib/session-checkout-apply.js +6 -3
  37. package/lib/session-checkout-apply.js.map +1 -1
  38. package/lib/session-checkout-module.js +6 -1
  39. package/lib/session-checkout-module.js.map +1 -1
  40. package/package.json +13 -13
  41. package/scripts/workspace-sidebar-resources.mjs +25 -0
  42. package/scripts/workspace-sidebar-upstream-alpha.mjs +2 -1
  43. package/scripts/workspace-sidebar-upstream-next.mjs +2 -1
  44. package/scripts/workspace-sidebar-upstream.mjs +2 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-git-worktree",
3
- "version": "0.11.0",
3
+ "version": "0.12.0",
4
4
  "description": "Experimental Git worktree Session Targets for DeepSeek Harness with isolated sessions, review checkpoints, human-confirmed delivery, and safe recovery.",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
@@ -89,18 +89,18 @@
89
89
  "peerDependencies": {
90
90
  "@deepseek-ai/cordis": "~4.0.5",
91
91
  "@deepseek-ai/cordis-plugin-loader": "~1.0.6",
92
- "@deepseek-ai/dsh-agent": "0.2.1-rc.2",
93
- "@deepseek-ai/dsh-client-locale": "0.2.1-rc.2",
94
- "@deepseek-ai/dsh-commands": "0.2.1-rc.2",
95
- "@deepseek-ai/dsh-fs": "0.2.1-rc.2",
96
- "@deepseek-ai/dsh-session": "0.2.1-rc.2",
97
- "@deepseek-ai/dsh-skill": "0.2.1-rc.2",
98
- "@deepseek-ai/dsh-skill-filesystem": "0.2.1-rc.2",
99
- "@deepseek-ai/dsh-subprocess": "0.2.1-rc.2",
100
- "@deepseek-ai/dsh-system-prompt": "0.2.1-rc.2",
101
- "@deepseek-ai/dsh-tools": "0.2.1-rc.2",
102
- "@deepseek-ai/dsh-typert-protocol": "0.2.1-rc.2",
103
- "@deepseek-ai/dsh-typert-registry": "0.2.1-rc.2",
92
+ "@deepseek-ai/dsh-agent": ">=0.2.1-rc.2",
93
+ "@deepseek-ai/dsh-client-locale": ">=0.2.1-rc.2",
94
+ "@deepseek-ai/dsh-commands": ">=0.2.1-rc.2",
95
+ "@deepseek-ai/dsh-fs": ">=0.2.1-rc.2",
96
+ "@deepseek-ai/dsh-session": ">=0.2.1-rc.2",
97
+ "@deepseek-ai/dsh-skill": ">=0.2.1-rc.2",
98
+ "@deepseek-ai/dsh-skill-filesystem": ">=0.2.1-rc.2",
99
+ "@deepseek-ai/dsh-subprocess": ">=0.2.1-rc.2",
100
+ "@deepseek-ai/dsh-system-prompt": ">=0.2.1-rc.2",
101
+ "@deepseek-ai/dsh-tools": ">=0.2.1-rc.2",
102
+ "@deepseek-ai/dsh-typert-protocol": ">=0.2.1-rc.2",
103
+ "@deepseek-ai/dsh-typert-registry": ">=0.2.1-rc.2",
104
104
  "react": "^18.2.0"
105
105
  },
106
106
  "devDependencies": {
@@ -0,0 +1,25 @@
1
+ const UPSTREAM_OWNER = '@deepseek-ai/dsh-client-ui-workspace'
2
+ const DERIVED_OWNER = 'dsh-git-worktree'
3
+
4
+ /** Embedded factories must not share CSS deduplication or cleanup identity.
5
+ * All variants materialize eagerly, even though only one Browser is applied.
6
+ * Keep the pinned CSS bytes/class maps; change only resource ownership/keys.
7
+ */
8
+ export function ownWorkspaceStyles(source, version, expectedStyles) {
9
+ let keys = 0
10
+ let owners = 0
11
+ const derived = source
12
+ .replace(/const tagId(\$\d+)? = "@deepseek-ai\/dsh-client-ui-workspace\/([^"/]+\.module\.css)";/gu,
13
+ (_match, suffix = '', file) => {
14
+ keys++
15
+ return `const tagId${suffix} = ${JSON.stringify(`${DERIVED_OWNER}/workspace-${version}/${file}`)};`
16
+ })
17
+ .replaceAll(`tag.dataset.plugin = "${UPSTREAM_OWNER}";`, () => {
18
+ owners++
19
+ return `tag.dataset.plugin = "${DERIVED_OWNER}";`
20
+ })
21
+ if (keys !== expectedStyles || owners !== expectedStyles) {
22
+ throw new Error(`Cannot derive Workspace ${version} CSS ownership: expected ${expectedStyles} keys/owners, got ${keys}/${owners}`)
23
+ }
24
+ return derived
25
+ }
@@ -1,6 +1,7 @@
1
1
  import { createHash } from 'node:crypto'
2
2
  import { readFileSync } from 'node:fs'
3
3
  import { createRequire } from 'node:module'
4
+ import { ownWorkspaceStyles } from './workspace-sidebar-resources.mjs'
4
5
  import { materializeWorkspaceFactory } from './workspace-sidebar-upstream-next.mjs'
5
6
 
6
7
  export const ALPHA_WORKSPACE_VERSION = '0.1.6-alpha.2'
@@ -100,5 +101,5 @@ export function decorateAlphaWorkspaceClient(source) {
100
101
  }
101
102
 
102
103
  export function materializeAlphaWorkspaceClientModule() {
103
- return materializeWorkspaceFactory(decorateAlphaWorkspaceClient(readAlphaWorkspaceClient()))
104
+ return materializeWorkspaceFactory(ownWorkspaceStyles(decorateAlphaWorkspaceClient(readAlphaWorkspaceClient()), ALPHA_WORKSPACE_VERSION, 3))
104
105
  }
@@ -1,6 +1,7 @@
1
1
  import { createHash } from 'node:crypto'
2
2
  import { readFileSync } from 'node:fs'
3
3
  import { createRequire } from 'node:module'
4
+ import { ownWorkspaceStyles } from './workspace-sidebar-resources.mjs'
4
5
 
5
6
  export const NEXT_WORKSPACE_VERSION = '0.1.7-rc.2'
6
7
  export const NEXT_WORKSPACE_SHA256 = '854722447794b79607651e6c75d0652db1aba376324f468ab8cd6ecdfe7d177f'
@@ -95,7 +96,7 @@ export function decorateNextWorkspaceClient(source) {
95
96
  }
96
97
 
97
98
  export function materializeNextWorkspaceClientModule() {
98
- return materializeWorkspaceFactory(decorateNextWorkspaceClient(readNextWorkspaceClient()))
99
+ return materializeWorkspaceFactory(ownWorkspaceStyles(decorateNextWorkspaceClient(readNextWorkspaceClient()), NEXT_WORKSPACE_VERSION, 4))
99
100
  }
100
101
 
101
102
  /** Load one pinned official Client factory without registering its upstream ModuleLoader row. */
@@ -1,6 +1,7 @@
1
1
  import { createHash } from 'node:crypto'
2
2
  import { readFileSync } from 'node:fs'
3
3
  import { createRequire } from 'node:module'
4
+ import { ownWorkspaceStyles } from './workspace-sidebar-resources.mjs'
4
5
 
5
6
  export const WORKSPACE_UI_VERSION = '0.2.1-rc.2'
6
7
  export const WORKSPACE_LOCALE_VERSION = '0.2.1-rc.2'
@@ -163,7 +164,7 @@ export function decorateOfficialWorkspaceClient(source) {
163
164
 
164
165
  export function materializeOfficialWorkspaceClientModule() {
165
166
  const official = readOfficialWorkspaceClient()
166
- const source = decorateOfficialWorkspaceClient(official.source)
167
+ const source = ownWorkspaceStyles(decorateOfficialWorkspaceClient(official.source), WORKSPACE_UI_VERSION, 4)
167
168
  const factoryToken = 'factory: (require) => {'
168
169
  const start = source.indexOf(factoryToken)
169
170
  const end = source.lastIndexOf('\n\t}\n});')