# operations

Typed wrappers around `git` shell commands — log, tag, commit, staging, status, and diff — returning structured data instead of raw text.

The commit family ([`commit`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-commit), [`amendCommit`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-amendCommit), [`amendCommitNoEdit`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-amendCommitNoEdit), [`createEmptyCommit`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-createEmptyCommit)) drives `git commit` with safe argument escaping ([`escapeFilePath`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-escapeFilePath), [`escapeAuthor`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-escapeAuthor)). The tag family covers creation ([`createTag`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-createTag)), querying ([`getTags`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getTags)), and lookup ([`getTag`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getTag)). Diff helpers ([`getChangedFilesBetween`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getChangedFilesBetween), [`getChangedFilesBetweenWithStatus`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getChangedFilesBetweenWithStatus), [`getCommitWithFiles`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getCommitWithFiles)) return typed `FileChange[]` and [`GitCommitWithFiles`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-GitCommitWithFiles) shapes. Status ([`getStatus`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-getStatus), returning [`RepositoryStatus`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-RepositoryStatus) with `FileStatusEntry[]`) and staging ([`stage`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-stage), [`discardChanges`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-discardChanges)) round out the everyday git surface. [`GitOperationState`](https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/#api-GitOperationState) captures retry/idempotency reasons for steps that can be safely re-run.

---

Canonical page: https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations/
This file: https://www.hyperfrontend.dev/docs/libraries/versioning/git/operations.md
Documentation index: https://www.hyperfrontend.dev/llms.txt
