_frontend/cli.py: Enhanced the `bst artifact --help` output
This clarifies that the wildcard expressions behave like bash's globstar
and supports `**` to match path separators, and is more clear about how
buildstream distinguishes elements from artifacts by requiring elements
be specified with a `.bst` suffix.
diff --git a/src/buildstream/_frontend/cli.py b/src/buildstream/_frontend/cli.py
index d2fcc62..9ce716d 100644
@@ -1190,20 +1190,28 @@
- artifact refs: triples of the form <project name>/<element name>/<cache key>
- - element paths
+ - element names
- When elements are given, the artifact corresponding to the element is used.
+ When elements are given, the artifact is looked up by observing the element
+ and it's current cache key.
The commands also support shell-style wildcard expansion: `?` matches a
- single character, and `*` matches zero or more. The patterns are matched
- against artifact refs by default. If the pattern ends with `.bst` then
- it matches element paths instead. Some example arguments are:
+ single character, `*` matches zero or more characters but does not match the `/`
+ path separator, and `**` matches zero or more characters including `/` path separators.
+ If the wildcard expression ends with `.bst`, then it will be used to search
+ element names found in the project, otherwise, it will be used to search artifacts
+ that are present in the local artifact cache.
+ Some example arguments are:
- - `*.bst` (all elements)
- - `myproject/*` (all artifacts from myproject)
+ - `core/*.bst` (all elements in the core directory)
+ - `**.bst` (all elements)
+ - `myproject/**` (all artifacts from myproject)
+ - `myproject/myelement/*` (all cached artifacts for a specific element)
# Note that the backticks in the above docstring are important for the
# generated docs. When sphinx is generating rst output from the help output