Commit Graph

7164 Commits

Author SHA1 Message Date
Alexander Larsson
469c4ae628 remote-ls: Display end-of-line status for remote refs
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
ea54fd0f68 repo: Show end-of-life info with branches
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
66699c0774 deploy: Store end-of-life data in deploy
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
8d7f888bf1 build-update-repo: Add end-of-line metadata to summary
This adds a "sparse-cache" metadata dict to the summary, where
we can add additional per-ref information that we don't expect
to be there for most refs. Initially we add the eol and
eol-rebase info to it so that we can see which remote refs
are end-of-line.

Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
42335c74a0 appstream: Don't include end-of-line refs in appdata
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
66ccf54c51 build-export/build-commit-from: Add --end-of-life option
This sets the ostree end of life marker for a commit, to mark
that this branch is no longer getting updates.

Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
0303433c7b table-printer: Add append_with_comma_printf
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
7a238f1860 tests/test-repo.sh: Ensure that appdata branch is built correctly
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
8e992e04ad flatpak-utils.c: Remove leftover spew
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
957544ca30 flatpak-utils: Mark strings for translation
Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Alexander Larsson
d4dc4fac0b build-commit-from: Remove duplicated short options
Several options were using -s, so only the first worked. Remove
the others.

Closes: #1566
Approved by: alexlarsson
2018-04-12 12:36:49 +00:00
Matthew Leeds
0695128d4b doc: Fix a few mistakes and inaccuracies
The flatpak-uninstall command now automatically chooses which
installation to use, so document that in the man page, and fix a few
other minor mistakes.

Closes: #1558
Approved by: alexlarsson
2018-04-09 07:44:07 +00:00
Kukuh Syafaat
fb574fecd1 Update Indonesian translation
Closes: #1561
Approved by: alexlarsson
2018-04-09 07:33:06 +00:00
Alexander Larsson
0a778dd7e2 Update to latest bubblewrap (0.2.1)
This has the NFS fix https://github.com/projectatomic/bubblewrap/pull/258
which means flatpak works on NFS.

Closes: #1559
Approved by: alexlarsson
2018-04-06 21:02:23 +00:00
Matthew Leeds
09e9d6896d README: Add an Oxford comma 2018-04-06 12:09:31 -05:00
Matthew Leeds
78199b066a lib: Add P2P support to list_installed_refs_for_update()
Currently flatpak_insallation_list_installed_refs_for_update() only
checks the configured remotes for updates. This means that updates from
peer sources such as USB drives or computers on the LAN are never seen,
which is especially problematic when the computer is offline. The end
result is that GNOME Software doesn't show an "Update" button to let you
update an app from a USB drive when you're offline.

This commit uses ostree API, primarily ostree_repo_find_remotes_async(),
to check peer sources for updates from any remotes that have a
collection ID configured. We're using an ostree 2018.5 feature from
https://github.com/ostreedev/ostree/pull/1518, but I used a version
check for that (it hasn't been released yet). Without it you can't tell
if an offered commit is an update or a downgrade, but that behavior is
still better than the status quo (no updates from P2P sources at all).

Closes: #1542
Approved by: alexlarsson
2018-04-06 15:38:21 +00:00
Matthew Leeds
73d1725bf2 testlibrary: Conditionally use a collection ID
Use a collection ID on the test repo if P2P support is enabled. This
will allow for testing of more API that makes use of collection IDs.

Closes: #1542
Approved by: alexlarsson
2018-04-06 15:38:21 +00:00
Matthew Leeds
c8fa36fca6 lib: Fix grammar in gtk-doc comments
Closes: #1542
Approved by: alexlarsson
2018-04-06 15:38:21 +00:00
Matthew Leeds
3f4f1f59b3 lib: Minor cleanups in list_installed_refs_for_updates
Closes: #1542
Approved by: alexlarsson
2018-04-06 15:38:21 +00:00
Piotr Drąg
a7d5b5a274 Update POTFILES.skip
Closes: #1552
Approved by: alexlarsson
2018-04-05 06:57:15 +00:00
Alexander Larsson
d3dee9f052 Better build fix 2018-04-04 17:50:06 +02:00
Alexander Larsson
c0862fcbb8 Fix builddir != srcdir build 2018-04-04 17:42:24 +02:00
Alexander Larsson
2cdb099ab3 Verify that the system cache directory supports user xattrs
Installation will fail with some weird error later if this is not true.
2018-04-04 17:31:31 +02:00
Alexander Larsson
a6ec434aed run: Escape : as \: in --filesystem= paths
This way we never get confused about which part of the argument
is the permission suffix, which could be exploitable if you can
control the --filesystem calls such as with sandboxed Spawns.
2018-04-04 17:25:59 +02:00
Alexander Larsson
11ef9999b6 Add flatpak portal
This listens to org.freedesktop.portal.Flatpak and lets flatpak
sandboxes do flatpak specific things.

Initially this only allows access to "Spawn", which lets you start a
new copy of the current or latest version of the calling app,
optionally with sandboxing.

This allows the app to re-start itself with the latest version after
an update, and the sandboxing is useful for apps that want to manually
sandbox part of themselves.

You can also expose one or more subdirectories of
~/.var/app/$appid/sandbox/ to the app, read-write or read-only. This is
useful to communicate with the sandbox.
2018-04-04 17:25:59 +02:00
Alexander Larsson
e9c6f30177 run: Add instance-path to .flatpak-info
This is the instance ~/.var/app/$appid dir
2018-04-04 17:25:59 +02:00
Alexander Larsson
74c4006dbe run: Add --sandbox
This runs the app in a very tight sandbox, with no access to anything
except /app and /run and some read-only host things like fonts and icons.

You can additionally add explicit permissions on the commandline,
like --share=network to actually grant some access.

This also sets $FLATPAK_SANDBOX_DIR to ~/.var/app/$appid/sandbox in the
environment.
2018-04-04 17:25:59 +02:00
Alexander Larsson
8570dcab85 run: Allow specifying an exact commit and runtime-commit
This also looks for removed but live deploys so that an app
can be re-started as long as it is live.
2018-04-04 17:25:59 +02:00
Alexander Larsson
21b9f3151b undeploy: Use predictable names for removed directories
This means if we undeploy something, but its still in use, then
we can find it later. This is interesting because it lets
us re-find it for spawning an instance of the same version.
2018-04-04 17:25:59 +02:00
Alexander Larsson
819a134506 flatpak-info: Add arch info 2018-04-04 17:25:59 +02:00
Alexander Larsson
43bcf38105 flatpak-info: Add instance-specific extra args
So, if you run your instance with e.g. flatpak run --filesystem=/some/dir
you can now see this. This will be useful in the restart yourself
portal as we can then inherit such permissions.
2018-04-04 17:25:59 +02:00
Alexander Larsson
513c0c36f5 update: Don't print appstream errors when quiet 2018-04-04 17:25:37 +02:00
Alexander Larsson
20c8420128 update: Fix updates of non-primary arches
When updating with no arch is specified we now update
appdata for all supported arches, and we don't look for
updates only of the primary arch.
2018-04-04 17:25:37 +02:00
Alexander Larsson
394130793c uninstall: Pick installation automatically
When uninstalling, if no specific installation was specified with e.g.
--user or --system, automatically chose any unique match, or error
out if there are multiple alternatives.

Fixes #1321
2018-04-04 17:25:20 +02:00
Alexander Larsson
3184a011c3 build-commit-from: Add --timestamp
This lets you override the timestamp from the source commits

Closes: #1538
Approved by: alexlarsson
2018-04-04 15:08:49 +00:00
Alexander Larsson
b9d8aeb175 build-export: Use parse_datetime() for --timestamp
This allows you more flexibility for defining the timestamp and
makes it compatilb with ostree commit.

Closes: #1538
Approved by: alexlarsson
2018-04-04 15:08:49 +00:00
Alexander Larsson
222d7e2382 Import parse_timestamp() from ostree
Closes: #1538
Approved by: alexlarsson
2018-04-04 15:08:49 +00:00
Matthew Leeds
4b002ebacd doc: Document --reinstall option
Closes: #1550
Approved by: alexlarsson
2018-04-04 14:55:14 +00:00
Matthew Leeds
aec0635869 Add a GitHub issue template 2018-04-03 10:08:35 +02:00
Rafael Fontenelle
53fd16da37 Update Brazilian Portuguese translation
Closes: #1534
Approved by: mwleeds
2018-04-02 22:54:49 +00:00
Alexander Larsson
bad8cc27f1 update: Complete from all installations
We currently auto-pick installation for update when you didn't pick
any specific one, so we should complete from all of them too.

Closes: #1537
Approved by: mwleeds
2018-04-02 20:33:09 +00:00
Alexander Larsson
b223590b6e Make flatpak remove an alias to flatpak uninstall
Yum, dnf and apt all use "remove" as the opposite of install, so
to make it easier for people coming from these.

Closes: #1536
Approved by: mwleeds
2018-03-30 07:06:00 +00:00
Alexander Larsson
2bf1bb3472 Add flatpak version to user agent
This uses the new ostree feature at:
  https://github.com/ostreedev/ostree/pull/1496

Note, this will only work with the current ostree master,
and does nothing on older versions.

Closes: #1533
Approved by: mwleeds
2018-03-28 20:19:10 +00:00
Matthew Leeds
3273e9923c dir: Improve "Can't find ref" error message
This commit adds the collection ID (if any) to the "Can't find ref"
error message produced by flatpak_dir_pull_untrusted_local(). This makes
the message more helpful if for example you run `flatpak update` when
some of the remotes are configured with the wrong collection IDs. It
also changes the wording to be consistent with other similar errors.

Closes: #1521
Approved by: mwleeds
2018-03-27 17:53:29 +00:00
Alexander Larsson
1840a7189c build-commit-from: Don't critical if commit has no commitmeta
Closes: #1524
Approved by: alexlarsson
2018-03-27 10:48:49 +00:00
Matthew Leeds
148b0ca245 doc: Update old command names
The add-repo command was renamed to remote-add, and repo-update was
renamed to build-update-repo, so update the man pages.
2018-03-26 21:54:25 -07:00
Nicholas Bishop
ab117ee250 Add all missing declarations to flatpak-sections.txt
Closes: #1505
Approved by: mwleeds
2018-03-23 22:55:11 +00:00
Matthew Leeds
8103a95a7f doc: Update name of repo-contents command
The repo-contents command was renamed to remote-ls in flatpak 0.4.0, so
rename it in the man pages.

Closes: #1516
Approved by: mwleeds
2018-03-23 22:42:26 +00:00
Matthew Leeds
f4acf169f2 doc: Fix typo in command name
Closes: #1515
Approved by: mwleeds
2018-03-23 22:25:47 +00:00
Matthew Leeds
e2c3157ea8 tests: Minor change to assertion ordering
Philip pointed out it's better to g_assert_no_error before g_assert_true
so the output shows the error message.

Closes: #1501
Approved by: pwithnall
2018-03-23 10:34:52 +00:00