Introduction

When using DeepSeek Harness (dsh) on Windows, the bash tool may fail to start. Common errors include:

PTY shell exited during startup
terminal inspection unsupported

The unavailability of the tool can affect task execution and may lead to more let me appearing in the thought chain. Jyleaves/dsh-win-bash-fix is used to fix the startup issues of the dsh bash tool on Windows, accompanied by two sets of thought chain presets: minimal-win and anchored-win. Below is an introduction to its positioning, features, installation methods, and precautions.

What is this

  • Plugin Name: Jyleaves/dsh-win-bash-fix
  • Maintainer: Jyleaves
  • License: MIT
  • Positioning: Makes dsh truly usable on Git Bash on Windows, accompanied by two well-formed thought chain presets (minimal-win / anchored-win)
  • Platform: Windows only (win32); plugin auto no-op on Linux/macOS
  • Verified Version: DSH version developed and verified on 0.1.0-rc.6 (latest npm) (2026-08-15)

Core Features

Fix dsh bash tool startup failure on Windows

The plugin handles the following issues:

  • dsh bash tool startup failure on Windows: PTY shell exited during startup / terminal inspection unsupported
  • Mount a no-op terminal inspector on win32 to bypass createProcessInspector restrictions
  • Inject MSYS environment variables to start Git Bash
  • Bypass conflicts between restricted-token file sandbox and MSYS2

The involved environment variables are as follows:

MSYSTEM
CHERE_INVOKING
MSYS2_PATH_TYPE
PATH

Pure Runtime Patch

The plugin works as a cordis plugin:

  • Does not modify dsh installation files
  • Automatically re-applies after dsh upgrades
  • Auto no-op on non-win32 platforms
  • Supports installing via install.mjs by choosing profile/home

Two Sets of Thought Chain Presets

The plugin comes with two presets:

  • minimal-win
  • anchored-win

Both presets are aimed at the collective thinking style of we / let's.

anchored-win has additional initial-round behaviors:

  • First round only exposes two tools: bash and edit
  • Restores the full Standard directory after the first tool call

Installation and Enablement

Method 1: Official Command Installation

Run the following command:

dsh plugin --profile web add github:Jyleaves/dsh-win-bash-fix

This command adds the plugin to the web profile.

Method 2: One-Click Copy Installation

Clone the repository and run the installation script:

git clone https://github.com/Jyleaves/dsh-win-bash-fix.git
cd dsh-win-bash-fix
node install.mjs

install.mjs supports choosing profile/home installation.

Method 3: Manual Installation

  1. Copy lib/index.js and preset-files/ to:
~/.dsh/profiles/web/win-bash-fix/
  1. Append the win-bash-fix mount block to cordis.patch.yml.

Enable

After installation is complete:

  1. Restart dsh web
  2. Hard refresh the browser

Typical Usage

After the steps above, you can use it as follows.

  1. Select the minimal-win or anchored-win preset when creating a new session.

  2. Send a task verifiable by the bash tool, for example:

先运行 pwd 和 ls 看看当前目录内容
  1. Choose effort based on task type:
  • Open-ended exploration tasks suggest effort=high
  • Specific tasks can use high or max
  1. If Git is not installed at the default path, set the GIT_ROOT environment variable before starting dsh. The default path is:
C:/Program Files/Git

For non-default installations, you can set it according to the actual path, for example:

GIT_ROOT=D:/Tools/Git
dsh web

Scenarios and Precautions

Suitable for scenarios on Windows where dsh is used, the bash tool is required to be available, and the thought chain is expected to maintain a we / let's style.

Pay attention to the following points before use:

  • Plugin only applicable to Windows (win32); auto no-op on Linux/macOS
  • Plugin depends on Git for Windows
  • Plugin is loaded at runtime while dsh runs and executes with dsh process permissions; check source code and license before installing
  • Shell tools (bash / pwsh) on Windows no longer go through the restricted-token file sandbox
  • Sandbox of fs tools (e.g., str_replace_editor) is independent and unaffected
  • When running untrusted code, please uninstall this plugin first
  • Plugin only modifies process.env and ~/.dsh/.agent-presets/
  • Plugin does not read user data, does not initiate network requests, and does not hold credentials
  • Plugin depends on dsh internal API (prototype patch); if dsh refactors internal shapes of related services, the plugin may silently fail
  • persistent bash timeout/PTY occasionally resetting to win32 is a known issue; timeout is a normal safeguard
  • Concurrent PTY has not been stress tested
  • Under max + open-ended exploration tasks, residual let me are action sentences, approximately 2/3 all green; 100% all green under high
  • v4-flash thought chain is in Chinese, has no English pronouns, and no let_me

Uninstall

If installed via the official command method, you can run:

dsh plugin --profile web remove @jyleaves/dsh-win-bash-fix

If installed via copy or manual method, you need to:

  1. Delete:
~/.dsh/profiles/web/win-bash-fix/
  1. Remove the win-bash-fix mount block from cordis.patch.yml.

Restart dsh after uninstalling.

Links