dsh-window-bounds: Remember the Window Size and Position of the DeepSeek Harness Desktop App

The official desktop shell (@deepseek-ai/dsh-desktop, Electron) hardcodes the main window to width: 1280, height: 820 in lib/main.js and does not expose any IPC channels related to window geometry—the preload bridge only carries updates, hotkeys, embedded browser views, and directory pickers. It has no capability to read or write the main window’s bounds, nor are there corresponding DSH_DESKTOP_* environment variables. The only remaining entry point is the window itself: pages on the dsh-app://app origin can call window.resizeTo() / window.moveTo().

What is this

flying4055/dsh-window-bounds is a memory plugin used to remember the window size and position of the DeepSeek Harness desktop application.

Core Features

  1. Remember the window size and position of the DeepSeek Harness desktop.
  2. Listen for the webserver’s index-inject event.
  3. Read saved geometry from localStorage.
  4. Validate against the current display.
  5. Debounced write-back to storage.
  6. Rejected geometry falls back to the shell’s default values.

Installation

dsh plugin --profile <profile> add flying4055/dsh-window-bounds

This package declares dsh.bundle.patch, so dsh plugin add will complete the installation, append the package name to the profile’s dsh.profile.bundles, and mount its cordis.patch.yml; the corresponding remove will revert all of these. Restart the profile after installation for it to take effect.

Notes

  • There is no configuration form in the plugin panel (this is intentional). The settings service in DSH 0.2.0-rc.2 uses Config !== undefined && 'toJSON' in Config to determine “whether this plugin’s Config is renderable,” and then treats the selected object as a schemastery schema. This plugin only exports ~standard but not toJSON, so naturally there are no fields for the panel to render.
  • The plugin is enabled by default.
  • Only size and position. Maximized and fullscreen states are not restored.
  • Single monitor workspace. Saved positions are only restored if they still fit within the current display.
  • The shell is the final authority.

To forget saved geometry, simply resize the window once and wait for it to be persisted, or delete the key in the desktop DevTools.

Plugin Directory

GitHub Repository

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye