From f5de6bf43ce661878c23096fc3cbb661aa191673 Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Fri, 30 Jan 2026 22:37:12 -0800 Subject: [PATCH] Clarify command hooks documentation about YAML sequences (#1255). --- docs/reference/configuration/command-hooks.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/reference/configuration/command-hooks.md b/docs/reference/configuration/command-hooks.md index 7c7f1eb6..8c4ef3ff 100644 --- a/docs/reference/configuration/command-hooks.md +++ b/docs/reference/configuration/command-hooks.md @@ -12,11 +12,15 @@ list of `commands:` in your borgmatic configuration file. For example: ```yaml commands: - before: action - when: [create] + when: [check] # This is an inline YAML sequence. run: - echo "Before create!" + - before: action + when: [create, prune] # Also an inline YAML sequence. + run: + - echo "Before create or prune!" - after: action - when: + when: # Multi-line YAML sequence, equivalent to "[create, prune]". - create - prune run: