Skip to content

@dsh-external/dsh-windows-shell-policy v0.0.1

Choose a tag to compare

@LAN-TINA-WS LAN-TINA-WS released this 21 Aug 00:37
· 8 commits to main since this release

v0.0.1 首版

Windows 默认 Shell 策略组合插件(hybrid 形态):探测 git-bash/MSYS2/Cygwin,在「设置 → 插件 → 插件配置」提供「默认 Shell」折叠卡片切换 bash/pwsh,动态注册 bash 工具并裁剪提示词工具面。

功能

  • bash 探测:显式 bashPath → Git 常见安装路径 → MSYS2/Cygwin → PATH
  • 配置面板折叠卡片(与官方卡片同构):自动 / bash / pwsh 三选一,staged 编辑 + 保存/放弃
  • 策略生效:auto 时探测到 bash 则用 bash 否则 pwsh;切换下一次请求生效
  • bash 工具:git-bash 执行(subprocess 通道),终端卡片展示(对话页可点击查看命令)
  • 提示词裁剪:agent 工具面只保留一个 shell 工具
  • 持久化:preferred 写入 settings 文档 shell-policy section
  • 卸载即净:dev_uninject_plugin 一键还原

安装

DSH_CHECKOUT=<checkout> bash scripts/build.sh
dev_inject_plugin <本目录>
# 或:node <harness>\apps\cli\lib\bin.js plugin --profile web add link:<repo>