| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
In _yaml.py and _frontend/complete.py we were getting pylint warnings
for using collections.Mapping and collections.Iterable, which are
abstract classes now provided from collections.abc. This patch just
uses the classes from the right place.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Following the message thread
https://mail.gnome.org/archives/buildstream-list/2018-November/msg00106.html,
implement a new command group called `source`. Move existing `track`,
`fetch`, and the recently added `source-checkout` commands under this
group.
For `track` and `fetch`, this is a BREAKING change, as the old commands
have been marked as obsolete. Using them will result in an error message
that refers people to use the new versions, like `bst source fetch`
instead of old `bst fetch`. `source-checkout` will now become
`source checkout` (the dash has turned into a space), and is not a
breaking change as it was added in the current development cycle.
Note that the functionality to hide commands from help output was added
only recently in Click, so the minimum version of Click that we now
require is 7.0.
Summary of changes:
* _frontend/cli.py: Add `source` command group, mark previous versions
as obsolete and hide them from the help output.
* _frontend/complete.py: Fix completion for hidden commands.
* setup.py: Bump Click minimum version to 7.0.
* tests: Update to cope with the new command names.
Fixes #814.
|
|
|
|
|
|
| |
Somehow I missed this when originally forking the file from the click
library, now noticing that we should have followed what was written
in: https://github.com/pallets/click/blob/master/LICENSE
|
|
|
|
|
|
|
|
| |
Element paths should always be completed from the root element folder
defined by the element-path key in project.conf. Fix complete_path() to
always search into its given base_directory argument.
See issue BuildStream/buildstream#448
|
|
|
|
| |
Fixes #424
|
|
|
|
|
|
| |
o This supports deeply nested commands as well as shallow commands
o Automated support for bash completions included
|
|
|
|
|
| |
The 'ctx' parameter is carefully threaded through to 'complete_target',
but it doesn't actually use it. Remove the parameter from unused places.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
subdirs
When completing .bst files in subdirectories of an 'element-path',
we need to take the element path into consideration when testing the
results of os.listdir() for os.path.isdir().
This makes directories behave like directories when completing
subdirs of project element paths.
|
|
|
|
|
|
|
|
|
|
| |
exiting
Leave that choice to the calling code.
Also some additional cleanup. Removed some bits of code borrowed
from click but unused in this context, just because it's futzing
up the coverage reports.
|
|
|
|
|
|
|
|
|
|
|
| |
The click completions code was written based on my branch
of click master, which I had been running locally.
Yesterday it worked but only against master, this patch
adds some extra customizations so that we can handle specific
arguments (like bst file targets) specially, and now it works
with stable releases of click, which means buildstream is
no longer broken also.
|
|
|
|
|
| |
Now we complete bst files in the project's element directory
when completions are available.
|
|
This is based on my branch of the click library where I was
unable to land a patch for this.
We should use an upstream solution once this issue is solved:
https://github.com/pallets/click/issues/780
|