The git-branchless
suite of tools now includes a revset-like language under the command git branchless query
.
Once installed and initialised on the current repository, the examples in the previous question (from eight years ago!) could be queried as follows:
# List patches not yet been merged into the branch default:
git branchless query "all() - ancestors('default')"
# List patches between the revision tagged 1.3 and the revision tagged
# 1.5 which which mention "bug" and affect a file in the directory hgext
git branchless query "1.3::1.5 and message('bug') and paths.changed('glob:hgext/*')"
These are remarkably similar to their HG equivalents.