---
name: "git-annex-pre-commit"
section: "1"
platform: "linux"
package: "git-annex"
version: "10.20261026-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/git-annex-pre-commit"
---

# git-annex-pre-commit(1)

run by git pre-commit hook

## NAME

git-annex-pre-commit - run by git pre-commit hook

## SYNOPSIS

git annex pre-commit **\[path ...\]**

## DESCRIPTION

This is meant to be called from git's pre-commit hook. **git annex init** automatically creates a pre-commit hook using this.

Fixes up symlinks that are staged as part of a commit, to ensure they point to annexed content.

When in a view, updates metadata to reflect changes made to files in the view.

## OPTIONS

- The [git-annex-common-options(1)](/git-annex-common-options/1.md) can be used.

  -

  ## SEE ALSO

[git-annex(1)](/git-annex/1.md)

## AUTHOR

Joey Hess \<id@joeyh.name\>
