Skip to content

docs(issues): add spec for migrating git hooks scripts from Bash to Rust (#1843) - #1844

Merged
josecelano merged 1 commit into
torrust:developfrom
josecelano:1843-migrate-git-hooks-scripts-from-bash-to-rust
May 27, 2026
Merged

josecelano merged 1 commit into
torrust:developfrom
josecelano:1843-migrate-git-hooks-scripts-from-bash-to-rust

Conversation

@josecelano

@josecelano josecelano commented May 27, 2026 •

Copy link
Copy Markdown
Member

Summary

Adds the implementation spec for issue #1843 — migrating the three git hook Bash scripts to a single Rust binary.

This PR contains only the spec file (docs/issues/open/1843-migrate-git-hooks-scripts-from-bash-to-rust.md). No implementation.

Changes

  • docs/issues/open/1843-migrate-git-hooks-scripts-from-bash-to-rust.md — new spec (moved from drafts/, prefixed with issue number, frontmatter updated)
  • project-words.txt — two new British English words (serialisation, summarising) added to pass cspell

Spec highlights

The spec covers a two-phase plan:

Phase 1 — Core migration (T1–T16): replace pre-commit.sh, pre-push.sh, and install-git-hooks.sh with a single torrust-git-hooks binary. Implements the same check steps with NDJSON output only (no --format=text switch). Switches over and removes the old scripts.

Phase 2 — Enhancements (T17–T22): heartbeat events for long-running steps, smart step skipping for docs-only staged commits, and idempotency cache to skip hooks that already passed for the same changes.

The binary must comply with the global CLI output contract ADR from day one (no-stdout-result class, NDJSON on stderr, exit codes 0/1/2).

Related

Related to #1843 (this PR merges only the spec; the issue remains open until implementation is complete)

Copilot AI review requested due to automatic review settings May 27, 2026 17:16
@josecelano josecelano self-assigned this May 27, 2026
@josecelano

Copy link
Copy Markdown
Member Author

ACK dafdec8

@josecelano
josecelano merged commit f148319 into torrust:develop May 27, 2026
1 check passed
@josecelano
josecelano removed the request for review from Copilot May 27, 2026 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant