When using "bundle-info BUNDLE --dependencies", information regarding
BUNDLE is presented to the user, this information includes the list of
direct and indirect dependencies BUNDLE has. All direct includes that
are optional (also-add) are marked as such, while there is no way to
distiguish what indirect dependencies are optional with the provided
information.
This commit expands the information shown by the command so indirect
dependencies that are optional are shown as such along with info about
the status of that dependency.
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
A spinner was added to swupd to show some kind of progress while
downloading content which its amount is unknown. Once the content is
downloaded the stopped spinner should be removed from the screen. This
commit does that.
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
This commit adds a function that can run an operation in one or all
3rd-party repositories. If a repository is specified then the operation
is run in only that 3rd-party repo, otherwise it is run in all 3rd-party
repos.
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
When os-install is used to install an OS and the --bundles option is used
to specify some bundles that should be installed in the system along
with the OS, the bundles specified should be tracked.
Closes#1153
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
Print a "Validate downloaded files" message to separate 2 different progress bars
and improve the output when downloading extra fullfiles
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
Changing the progress report lib to always print 0 or -1 when a step is
started and a 100 when a step finishes.
Also reorganizing all commands to have less steps (when possible) and that
are more meaningful to progress report. Hide some internal steps that doesn't
provide useful information to end users.
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
This ensures we have a callback function
for full_file curl download. The function
implements a spinner for progress
Fixes#1060
Signed-off-by: Karthik Prabhu Vinod <karthik.prabhu.vinod@intel.com>
Never use on tests fake url without specifying the protocol because proxies can
respond differently. Use https pointing to localhost in this cases.
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
Instead of initializing curl library on start, initialize it only when needed.
The advantage of this approach is that we can run some commands offline, if
there's no file to download.
Fixes#801Fixes#895Fixes#277
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
When the --download flag is set for the os-install command, update
content will be downloaded to the statedir and no content will be
installed.
Signed-off-by: John Akre <john.w.akre@intel.com>
Circular includes shoudn't exist, but we can handle that without crashing.
Also-add circular includes are common and expected. So we just add the
first occurence found.
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
In the case that we have a bundle installed as also-add and removed later,
repair shouldn't reinstall that bundle. The same is valid for diagnose and update.
Os-install is the only exception. We should always install all bundles that are
listed as also-add in os-install.
Signed-off-by: Otavio Pontes <otavio.pontes@intel.com>
This commit adds a few more cosmetic changes to the commands that run
verify in the back for consistency.
- Different steps in the update process are separated by a blank line.
- Messages from swupd should not finish with a '.'
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
Currently when running diagnose, and a problem is found (a missing
file, a corrupt file, or an extraneous file), swupd shows the output
like this:
Verifying files
...12%
Hash mismatch for file: /usr/bin/somefile
...100%
Inspected 632545 files
So it splits the percentage that shows the progress of the action in two
lines. This commit fixes the output so it looks like this instead:
Checking for missing files
...100%
Checking for corrupt files
-> Hash mismatch for file: /usr/bin/mixer
-> Hash mismatch for file: /usr/bin/mixin
-> Hash mismatch for file: /usr/bin/swupd-extract
-> Hash mismatch for file: /usr/bin/swupd-inspector
-> Hash mismatch for file: /usr/share/zsh/site-functions/_mixer
...100%
Checking for extraneous files
...100%
Inspected 632545 files
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
This commit adds a line break at the end of the progress report (when we
reach 100%) so we don't have to manually include it every time we report
progress.
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>
The purpose of swupd verify --install is so it can be used to install
a new Clear OS in a target system. However since currently it is part
of the swupd verify command it makes it confusing as of to what its
purpose is.
This commit moves the swupd verify --install option to be a top level
command (swupd os-install) so its purpose is more straightforward. The
new command still uses the verify code to perform the task underneath.
Signed-off-by: Castulo Martinez <castulo.martinez@intel.com>