diff options
| author | Brice Waegeneire <brice@waegenei.re> | 2025-06-22 12:28:48 +0200 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2025-06-30 14:30:40 +0200 |
| commit | c6b4fe16f467cca745bcbb0acd75a5eb35d22a50 (patch) | |
| tree | 9b57c3de1cac5712225a66078142a0082738a364 /Makefile.am | |
| parent | aa2f243ab724ead8f7c06f0a9dc8c1a4874de7fe (diff) | |
build: Create .git/hooks/.
* Makefile.am (.git/hooks/): Add.
(.git/hooks/%, .git/hooks/commit-msg): Depend on .git/hooks/.
Change-Id: I5e027d22ec71b8cb080dca2971fabb85c593cb35
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'Makefile.am')
| -rw-r--r-- | Makefile.am | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am index e5f7dfefe18..90dfc570e5b 100644 --- a/Makefile.am +++ b/Makefile.am | |||
| @@ -20,6 +20,7 @@ | |||
| 20 | # Copyright © 2023 Clément Lassieur <clement@lassieur.org> | 20 | # Copyright © 2023 Clément Lassieur <clement@lassieur.org> |
| 21 | # Copyright © 2023, 2024 Wilko Meyer <w@wmeyer.eu> | 21 | # Copyright © 2023, 2024 Wilko Meyer <w@wmeyer.eu> |
| 22 | # Copyright © 2024 gemmaro <gemmaro.dev@gmail.com> | 22 | # Copyright © 2024 gemmaro <gemmaro.dev@gmail.com> |
| 23 | # Copyright © 2025 Brice Waegeneire <brice@waegenei.re> | ||
| 23 | # | 24 | # |
| 24 | # This file is part of GNU Guix. | 25 | # This file is part of GNU Guix. |
| 25 | # | 26 | # |
| @@ -1248,7 +1249,12 @@ cuirass-jobs: $(GOBJECTS) | |||
| 1248 | .PHONY: update-guix-package update-NEWS cuirass-jobs release | 1249 | .PHONY: update-guix-package update-NEWS cuirass-jobs release |
| 1249 | 1250 | ||
| 1250 | # Git auto-configuration. | 1251 | # Git auto-configuration. |
| 1251 | .git/hooks/%: etc/git/% | 1252 | .git/hooks/: |
| 1253 | $(AM_V_at)if test -d .git; then \ | ||
| 1254 | mkdir "$@"; \ | ||
| 1255 | fi | ||
| 1256 | |||
| 1257 | .git/hooks/%: etc/git/% | .git/hooks/ | ||
| 1252 | $(AM_V_at)if test -d .git; then \ | 1258 | $(AM_V_at)if test -d .git; then \ |
| 1253 | cp "$<" "$@"; \ | 1259 | cp "$<" "$@"; \ |
| 1254 | fi | 1260 | fi |
| @@ -1260,7 +1266,7 @@ cuirass-jobs: $(GOBJECTS) | |||
| 1260 | fi | 1266 | fi |
| 1261 | 1267 | ||
| 1262 | COMMIT_MSG_MAGIC = VGhpcyBpcyB0aGUgY29tbWl0LW1zZyBob29rIG9mIEd1aXg= | 1268 | COMMIT_MSG_MAGIC = VGhpcyBpcyB0aGUgY29tbWl0LW1zZyBob29rIG9mIEd1aXg= |
| 1263 | .git/hooks/commit-msg: etc/git/commit-msg | 1269 | .git/hooks/commit-msg: etc/git/commit-msg | .git/hooks/ |
| 1264 | $(AM_V_at)if test -d .git; then \ | 1270 | $(AM_V_at)if test -d .git; then \ |
| 1265 | if test -f $@ && ! grep -qF $(COMMIT_MSG_MAGIC) $@; then \ | 1271 | if test -f $@ && ! grep -qF $(COMMIT_MSG_MAGIC) $@; then \ |
| 1266 | mkdir -p $@.d && mv $@ $@.d && \ | 1272 | mkdir -p $@.d && mv $@ $@.d && \ |
