Skip to content

Commit a0fb114

Browse files
Delete the TypeScript pipeline DSL (#158)
1 parent 6870433 commit a0fb114

4 files changed

Lines changed: 10 additions & 18 deletions

File tree

‎.claude/skills/write-pipeline/SKILL.md‎

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: write-pipeline
33
description: Write or modify Harmont CI pipelines. Use when creating new pipelines, adding/removing steps, switching toolchains, customizing caching/triggers, or when the user asks to set up CI with Harmont. Fetches live documentation from docs.harmont.dev for up-to-date API reference.
44
---
55

6-
Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Python) or `.hm/pipeline.ts` (TypeScript). Pipelines are real programs that import the `harmont` SDK and declaratively define build steps, triggers, and caching.
6+
Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py`. Pipelines are real Python programs that import the `harmont` SDK and declaratively define build steps, triggers, and caching.
77

88
## When to use
99

@@ -46,11 +46,7 @@ Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Pyth
4646

4747
1. **Identify the project's language and build system.** Look at the project root for `Cargo.toml` (Rust), `package.json` (JS/TS), `pyproject.toml` or `setup.py` (Python), `go.mod` (Go), `CMakeLists.txt` (C/C++), `mix.exs` (Elixir), `build.zig` (Zig).
4848

49-
2. **Check for an existing pipeline.** Look for `.hm/pipeline.py` or `.hm/pipeline.ts`. If none exists, pick the DSL that matches the project's ecosystem before asking the user to confirm:
50-
- **TypeScript DSL** if the project already has `package.json`, `tsconfig.json`, or is primarily TypeScript/JavaScript (the team is already comfortable with the TS toolchain).
51-
- **Python DSL** for everything else — Rust, Go, C/C++, Elixir, Zig, Python, or mixed-language projects (Python is the simpler, more universal choice).
52-
- Present your recommendation and rationale, then let the user override if they prefer the other DSL.
53-
Then either run `hm init --template <kind>` to scaffold or write the pipeline file directly.
49+
2. **Check for an existing pipeline.** Look for `.hm/pipeline.py`. If none exists, run `hm init --template <kind>` to scaffold or write the pipeline file directly.
5450

5551
3. **Fetch the relevant documentation** (see "Before you start" above). Always fetch the patterns guide first. Then fetch the toolchain reference for the detected language.
5652

@@ -101,7 +97,7 @@ Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Pyth
10197

10298
- **Always fetch documentation before writing pipelines.** The SDK evolves; do not rely on memorized API surfaces. The `.md` suffix on any docs.harmont.dev URL returns raw Markdown suitable for reading.
10399
- **Prefer toolchains over raw shell.** The patterns guide explains why. Only use `hm.sh()` / `sh()` for custom commands that no toolchain covers.
104-
- Pipelines live in `.hm/pipeline.py` or `.hm/pipeline.ts` — never both in the same project.
100+
- Pipelines live in `.hm/pipeline.py`.
105101
- `hm run` is the ONLY correct way to validate a pipeline locally. Do NOT try to run pipeline steps manually.
106-
- The Python DSL uses decorators (`@hm.pipeline`). The TypeScript DSL uses an exported `PipelineDefinition[]` array with `export default`.
102+
- The DSL uses decorators (`@hm.pipeline`, `@hm.target`).
107103
- Do NOT file GitHub issues without the user's explicit permission.

‎crates/hm-dsl-engine/harmont-py/tests/test_js.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ def test_skips_detection_when_pm_set(self, tmp_path) -> None:
345345

346346

347347
# ---------------------------------------------------------------------------
348-
# Corepack version pin (parity with the TypeScript DSL)
348+
# Corepack version pin
349349
# ---------------------------------------------------------------------------
350350

351351

‎crates/hm/src/commands/init_templates/skill_convert_gha.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ Convert existing GitHub Actions workflows (`.github/workflows/*.yml` / `*.yaml`)
5959
| `matrix:` | Multiple pipelines or parameterized steps | No direct matrix — may need separate pipeline definitions or `.fork()` |
6060
| `env:` / `secrets.*` | `env: {}` on pipeline or step | Secrets must be passed as environment variables |
6161
| `actions/upload-artifact` / `actions/download-artifact` | Step outputs and DAG dependencies | Harmont passes outputs between steps via the DAG |
62-
| `if:` conditionals | Pipeline-level logic (Python/TS) | Use the DSL's native control flow |
62+
| `if:` conditionals | Pipeline-level logic (Python) | Use the DSL's native control flow |
6363

6464
3. **Be honest about differences.** After presenting the mapping, explain:
6565
- **What's simpler:** Caching is implicit — no `actions/cache` boilerplate. No `actions/checkout` needed. Toolchains replace `actions/setup-*` with cleaner configuration.

‎crates/hm/src/commands/init_templates/skill_write_pipeline.md‎

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: write-pipeline
33
description: Write or modify Harmont CI pipelines. Use when creating new pipelines, adding/removing steps, switching toolchains, customizing caching/triggers, or when the user asks to set up CI with Harmont. Fetches live documentation from docs.harmont.dev for up-to-date API reference.
44
---
55

6-
Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Python) or `.hm/pipeline.ts` (TypeScript). Pipelines are real programs that import the `harmont` SDK and declaratively define build steps, triggers, and caching.
6+
Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py`. Pipelines are real Python programs that import the `harmont` SDK and declaratively define build steps, triggers, and caching.
77

88
## When to use
99

@@ -46,11 +46,7 @@ Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Pyth
4646

4747
1. **Identify the project's language and build system.** Look at the project root for `Cargo.toml` (Rust), `package.json` (JS/TS), `pyproject.toml` or `setup.py` (Python), `go.mod` (Go), `CMakeLists.txt` (C/C++), `mix.exs` (Elixir), `build.zig` (Zig).
4848

49-
2. **Check for an existing pipeline.** Look for `.hm/pipeline.py` or `.hm/pipeline.ts`. If none exists, pick the DSL that matches the project's ecosystem before asking the user to confirm:
50-
- **TypeScript DSL** if the project already has `package.json`, `tsconfig.json`, or is primarily TypeScript/JavaScript (the team is already comfortable with the TS toolchain).
51-
- **Python DSL** for everything else — Rust, Go, C/C++, Elixir, Zig, Python, or mixed-language projects (Python is the simpler, more universal choice).
52-
- Present your recommendation and rationale, then let the user override if they prefer the other DSL.
53-
Then either run `hm init --template <kind>` to scaffold or write the pipeline file directly.
49+
2. **Check for an existing pipeline.** Look for `.hm/pipeline.py`. If none exists, run `hm init --template <kind>` to scaffold or write the pipeline file directly.
5450

5551
3. **Fetch the relevant documentation** (see "Before you start" above). Always fetch the patterns guide first. Then fetch the toolchain reference for the detected language.
5652

@@ -101,7 +97,7 @@ Write, modify, or extend Harmont CI pipelines defined in `.hm/pipeline.py` (Pyth
10197

10298
- **Always fetch documentation before writing pipelines.** The SDK evolves; do not rely on memorized API surfaces. The `.md` suffix on any docs.harmont.dev URL returns raw Markdown suitable for reading.
10399
- **Prefer toolchains over raw shell.** The patterns guide explains why. Only use `hm.sh()` / `sh()` for custom commands that no toolchain covers.
104-
- Pipelines live in `.hm/pipeline.py` or `.hm/pipeline.ts` — never both in the same project.
100+
- Pipelines live in `.hm/pipeline.py`.
105101
- `hm run` is the ONLY correct way to validate a pipeline locally. Do NOT try to run pipeline steps manually.
106-
- The Python DSL uses decorators (`@hm.pipeline`). The TypeScript DSL uses an exported `PipelineDefinition[]` array with `export default`.
102+
- The DSL uses decorators (`@hm.pipeline`, `@hm.target`).
107103
- Do NOT file GitHub issues without the user's explicit permission.

0 commit comments

Comments
 (0)