From b0276d1bf11cc6f26cfbdbd1d1d134fda36a82fb Mon Sep 17 00:00:00 2001 From: James Sully Date: Tue, 5 Sep 2023 23:11:20 +1000 Subject: [PATCH] Update docs/revsets.md: document `ancestors(x[, depth])` optional parameter --- docs/revsets.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/revsets.md b/docs/revsets.md index 1d78f1b2fa..c48740d8be 100644 --- a/docs/revsets.md +++ b/docs/revsets.md @@ -79,7 +79,8 @@ revsets (expressions) as arguments. * `parents(x)`: Same as `x-`. * `children(x)`: Same as `x+`. -* `ancestors(x)`: Same as `:x`. +* `ancestors(x[, depth])`: Last `depth` ancestors of `x` (including `x` + itself). `ancestors(x)` is the same as `:x`, returning all ancestors. * `descendants(x)`: Same as `x:`. * `connected(x)`: Same as `x:x`. Useful when `x` includes several commits. * `all()`: All visible commits in the repo.