Skip to content

CLI and configuration

Harmony adds one command group to the existing dsh launcher.

Commands

dsh harmony

Open the plugin-order TUI. The Web profile is the default.

sh
dsh harmony
dsh harmony --profile tui

dsh harmony status

Print every collected Patch and its state. The command exits with code 1 when any Patch has failed.

sh
dsh harmony status
dsh harmony status --profile tui

dsh harmony inspect

Print original, intermediate, and final source for collected targets.

sh
dsh harmony inspect
dsh harmony inspect some-dsh-plugin
dsh harmony inspect some-dsh-plugin --file lib/index.js

All commands accept --profile <name>.

Profile state

Each profile stores Harmony state at:

text
$DSH_HOME/profiles/<name>/harmony.json

The file contains the manual plugin order and disabled stable Patch keys. Harmony synchronizes it with installed dependencies: new plugins append to the order and removed plugins disappear.

Do not edit the file while the profile is running. Use Web Settings or the TUI so the candidate state is preflighted and committed transactionally.

Provider metadata

Provider configuration belongs under dsh.harmony in package.json:

json
{
  "dsh": {
    "harmony": {
      "patches": ["./patches/a.cjs", "./patches/b.cjs"],
      "after": ["provider-a"],
      "before": ["provider-c"],
      "conflicts": ["legacy-provider"]
    }
  }
}
FieldMeaning
patchesCommonJS Patch modules in declaration order
beforeProvider package names this provider prefers to precede
afterProvider package names this provider prefers to follow
conflictsProvider package names that produce an incompatibility warning

Environment

VariablePurpose
DSH_HOMEOverrides the Harness home that contains profiles and Harmony state
DSH_HARMONY_DSH_ENTRYSelects an explicit official @deepseek-ai/dsh/lib/bin.js, primarily for Desktop integration

Stable Patch keys

Harmony combines the provider package name and Patch id into a stable key:

text
provider-package/patch-id

Status output, enablement, inspection, dependencies, and errors use this key. Disabling <provider>/* disables the whole provider and removes its active conflict warnings.

Released under the MIT License.