In some cases, when NULL was passed for an OstreeProgress,
the library code would instantate its own progress object
and write progress information out to the console. That
is not a good thing for a library to do - it has the
potential to mess up the cli tools output.
Stop doing this, and require that all callers pass
a non-NULL progress.
Closes: #2468
Approved by: alexlarsson
The new function, flatpak_compete_columns, takes an array
of Column structs and completes a --columns= option.
Unfortunately, bash completion does not let us do better
than repeating the entire list of columns for every
possible completion. This is not ideal, but at least
it gives good results for the first column.
Closes: #2445
Approved by: alexlarsson
Ostree just gives us a generic G_IO_ERROR_FAILED (boo!),
so we need to scrape the message to infer that this was
out-of-space. Translate this to an explicit error code
that we handle in the UI.
Closes: #2477
Approved by: alexlarsson
test-info.sh was needlessly relying on the exact output
of flatpak info --show-extensions. Update it to match the
new output.
Closes: #2502
Approved by: alexlarsson
printf(), and by extension, g_print() interprets
field width in terms of bytes, not characters.
Therefore, using %*s for padding strings with
non-ASCII characters does not work. Instead, use
the new utility function for aligned lines.
Closes: #2502
Approved by: alexlarsson
printf(), and by extension, g_print() interprets
field width in terms of bytes, not characters.
Therefore, using %*s for padding strings with
non-ASCII characters does not work. Instead, use
the new utility function for aligned lines.
While we are doing this, also fix up the alignment of
the extension sections in the output.
Closes: #2502
Approved by: alexlarsson
Add a new utility for printing
TITLE: value
while properly handling Unicode wrt to alignment.
This will be shared between info and remote-info.
Closes: #2502
Approved by: alexlarsson
We are allowing Unicode output, so we need to
use g_utf8_strlen whenever we want to count the
number of columns occupied by a string.
Closes: #2502
Approved by: alexlarsson
Be more systematic about returning FLATPAK_ERROR unmodified
and wrap everything else in a G_DBUS_ERROR_FAILED.
Closes: #2391Closes: #2532
Approved by: alexlarsson
These options were not showing up in completion,
and, if present in the commandline, would prevent
further completion, despite being accepted by
the run command.
Closes: #2534
Approved by: alexlarsson
The info command has its own --system/--user/--installation
options, but it was not setting a name for the argument
of --installation. This was showing up in the completion
missing a '=' after --installation.
Closes: #2534
Approved by: alexlarsson
I was seeing some issues because make check was
picking up a custom installation that was defined
in /etc/flatpak/installations.d/ on my system.
Avoid that by pointing FLATPAK_CONFIG_DIR at
a non-existing place.
Closes: #2534
Approved by: alexlarsson
Move this typedef to flatpak-complete.h, where it
belongs. Also add a autoptr definition for it and use
it to avoid leaking the completion in flatpak-main.c.
Closes: #2534
Approved by: alexlarsson
We can look at the error that is returned
by flatpak_transaction_run, no need for this
cli-transaction specific api.
Note that we need to be a little careful to
return the expected error: when there is
an operation error, we need to return that,
instead of an ABORTED error.
Update all users.
Closes: #2556
Approved by: alexlarsson
When reinstalling refs during repair, the formatted
output of FlatpakCliTransaction is not appropriate.
Use a FlatpakQuietTransaction instead.
Closes: #2556
Approved by: alexlarsson
Move this minor convenience api into its only user.
Using only generic FlatpakTransaction apis lets us
switch out transaction instances easily.
Closes: #2556
Approved by: alexlarsson