| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Providing a remote will limit build's pull/push remote actions to
the given remote specifically, ignoring those defined via user or
project configuration.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a breaking change, as it affects behaviour that people might be
relying on. An entry has been added to NEWS.
As proposed on the mailing list, this change removes the unconditional
prompts on:
o: bst workspace reset
o: bst workspace close --remove-dir
If interactive, these commands would always interrupt you with a prompt
like this:
This will remove all your changes, are you sure?
This seems like it may just save someone's work some time. It may also
condition folks to hit 'y' quickly without thinking.
This change also makes the non-interactive behaviour consistent with the
interactive behaviour in the default case. There is also the case of the
prompt configured by 'really-workspace-close-project-inaccessible',
which may be tackled in later work.
This change also removes the new config options to suppress those
prompts, and their associated news entry.
The relevant bit of the mailing list conversation is here:
https://mail.gnome.org/archives/buildstream-list/2018-December/msg00106.html
The issue to make interactive and non-interactive behaviour consistent
is here:
https://gitlab.com/BuildStream/buildstream/issues/744
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Provide bst shell --use-buildtree the ability to attempt to
acquire missing buildtrees, given respective option, user
pull-buildtree context and remote availability.
_frontend/cli.py: Refactor logic for determining --use-buildtree
option with given opportunity to attempt pulling a non-local
buildtree. Element loaded with artifact_config to allow remote
querying.
_stream.py: With given user option and element state, construct
PullQueue to fetch remote buildtree. Continue or Error without
buildtree if cannot be attained.
tests/integration/build-tree.py: Update to support new usecases
|
|
|
|
|
|
|
| |
Junctions cannot be built, pulled, or pushed. Specifying a junction on
the command line for these commands will result in an error. However,
junctions may be in the list of default targets, so they need to be
ignored for build, pull, and push commands.
|
|
|
|
|
|
| |
_frontend/cli.py: Use new methods.
Based on patches by Phillip Smyth.
|
|
|
|
| |
There is no reason to disallow guess_element() for bst build --all.
|
|
|
|
|
|
|
|
|
| |
Click 7.0 allows us to declare commands as 'hidden'.
However, sphinx-click and click-man still generate these hidden
commands in the documentation and man pages, respectively.
This is a stop gap solution until the upstream issues (tracked in
issues #879 and #881) have been addressed.
|
|
|
|
|
|
|
|
|
|
|
| |
This commit marks 'bst checkout' as a 'hidden' command. If used,
the user will be prompted to use the new 'bst artifact checkout'
command.
All tests which used 'bst checkout' have been modified to use
the new artifact sub-command.
This partially solves #822.
|
|
|
|
|
|
| |
'artifact checkout' has slightly different behaviour from 'checkout',
that is, either '--directory' or '--tar' are now required options.
This is a step towards allowing checkout to take multiple args.
|
|
|
|
|
| |
This commit also ensures that if we try to use the 'old' commands,
BuildStream will fail and instruct the user to use the new command.
|
| |
|
|
|
|
|
|
|
| |
The path of the config file generated by testutils for completion tests
is passed as regular argument, not via COMP_WORDS. Use that config file
in complete_artifact() to ensure the test uses the right artifact
directory.
|
|
|
|
|
|
| |
Moving fetch and track to the source command group accidentally dropped
the support for guessing targets for these commands when invoked from a
workspace directory. This brings it back.
|
| |
|
|
|
|
| |
Fixes issue #740
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
| |
|
| |
|
|
|
|
| |
This is part of the work towards #672
|
| |
|
| |
|
|
|
|
| |
This commit is part of the work towards #672
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Known issues:
* `bst shell` works, but `bst shell COMMANDS...` doesn't, because click
has no way of separating optional args from variable-length args.
* `bst checkout` and `bst source-checkout`'s usage strings mark LOCATION
as an optional argument. Because click gets confused if there's an
optional argument before a mandatory argument, I had to mark LOCATION
as optional internally.
* `bst workspace open` makes no sense with element being optional, so
I skipped it.
* `bst workspace close` will probably need to be revisited when multiple
projects can own one workspace.
* `bst workspace reset` will happily delete the directory you're
currently in, requiring you to `cd $PWD` to see the contents of your
directory.
I could exclude the top-level directory of the workspace being
deleted, but it is entirely valid to run workspace commands from deeper
in the workspace.
This is a part of #222
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
using to load the project
This involves changes in:
* _stream.py:
* Add the helper Stream.workspace_is_required()
* userconfig.yaml:
* Add a default value for prompt.really-workspace-close-project-inaccessible
* _context.py:
* Load the prompt 'really-workspace-close-project-inaccessible' from
user config.
* cli.py:
* If buildstream is invoked interactively, prompt the user to confirm
that they want to close the workspace they're using to load this
project.
This is a part of #222
|
|
|
|
| |
This is a part of #222
|
|
|
|
|
|
|
|
| |
Before we would have a intricate logics with multiple arguments
that might get ignored.
This simplifies the design and introduces a bool `shell` instead
of having two different variables concerned about scope
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As discussed in
https://mail.gnome.org/archives/buildstream-list/2018-September/msg00064.html,
add `--deps build` option to `bst checkout`. This will allow users to
checkout the all build dependencies of a given element using a single
command.
- _frontend/cli.py: Add `--deps build` option for `bst checkout`.
- element.py: Support `deps='build'` in Element._prepare_sandbox().
- tests/frontend/buildcheckout.py: Ensure `--deps build` works as
expected.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Adds helper function _buildtree_pull_required() to determine if a
pullqueue should be constructed, for commands outside of bst pull
and build where it is determined that an element's buildtree
artifact is to be required given the respective semantics and
config. Utilised in push() to attempt to mitigate skipping the push
of partial elements without the user having to have preceded it with
an explicit pull.
cli.py: Add new behaviour to push command description
element.py: Move _cached_buildtree() to be non local private method,
use _KeyStrength types to reduce duplication.
tests/integration/pullbuildtrees.py also updated to cover this
use-case.
|
|
|
|
|
|
|
| |
This is to update the workspace CLI to as agreed on the mailing list
https://mail.gnome.org/archives/buildstream-list/2018-September/msg00046.html
This patch also introduces the default workspace directory.
|
|
|
|
|
|
|
|
|
|
| |
Provide options in project.conf to disable the 'Are you sure ...'
prompts when making destructive changes:
- Add prompt.really-workspace-close-remove-dir
- Add prompt.really-workspace-reset-hard
Add a NEWS item for these.
|
|
|
|
|
|
|
|
|
|
|
|
| |
As discussed in
https://mail.gnome.org/archives/buildstream-list/2018-September/msg00064.html,
add `bst source-checkout` command. This will allow users to checkout
sources for a given target.
* _frontend/cli.py: Add source-checkout command
* _pipeline.py: Add assert_sources_cached() method
* _stream.py: Add source_checkout method, abstract out
__check_location_writable() method that used to part of checkout()
|
|
|
|
|
|
|
|
|
|
|
|
| |
_context.py: Add pull_buildtrees global user context, the default
of which is set to False via the addition of pull-buildtrees to
userconfig.yaml cache group.
_frontend/app.py & cli.py: Add --pull-buildtrees as a bst main
option, which when passed will override the default or user defined
context for pull_buildtrees.
tests/completions/completions.py: Update for the added flag.
|
| |
|
|
|
|
|
|
|
| |
In user config (buildstream.conf), it is set with the "default-mirror"
field.
On the command-line, it is set with "--default-mirror"
|
|
|
|
|
|
|
|
| |
One of the tests added is configured to be skipped for now, as dumping
binary data is causing a bad descriptor exception when using the pytest
capture module.
Closes #263.
|
|
|
|
|
|
|
| |
Before this option was listed in help but was ignored when
creating the source-bundle.
Issue #468
|
| |
|
|
|
|
|
| |
buildstream/_stream.py: Added deps param to _prepare_sandbox function call
buildstream/element.py: Added deps param and logic to _prepare_sandbox function
|
|
|
|
| |
It was redirecting for checkout operations
|
|
|
|
|
| |
This is to avoid inconsistencies when dealing with paths inside an
elements directory
|
|
|
|
|
|
|
|
|
|
|
| |
Workspaces are now index by colon separated junction path. This
now allows to create workspaces for elements in external projects.
Workspaces are owned by context instead of root project. However
it is initialized once top-level project is registered as we need
to resolve paths relatively to this top-level project.
Part of #359.
|
|
|
|
|
|
| |
o This supports deeply nested commands as well as shallow commands
o Automated support for bash completions included
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
subdirectory
The previous commit added support for running bst commands form
subdirectories of the project root. Make autocomplete also work in a
similar way.
|
|
|
|
| |
i.e. when an element is specified, it may be replaced with its source element.
|
|
|
|
|
|
|
|
| |
Opens the door to platform specific frontend features,
and implements a platform specific "notify" method.
This is based on Valentin David's patch on merge request 447,
and this fixes issue #385.
|
|
|
|
| |
This is in preparation for moving away from summary files.
|