[gnome-boxes/nightly-gnome-images: 11/11] WIP
- From: Felipe Borges <felipeborges src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes/nightly-gnome-images: 11/11] WIP
- Date: Wed, 19 Feb 2020 13:41:32 +0000 (UTC)
commit 188087ce1d2447bf56bf3ee6f45dcaf174a71247
Author: Felipe Borges <felipeborges gnome org>
Date: Tue Feb 11 16:32:26 2020 +0100
WIP
data/osinfo/gnome-nightly.xml | 43 ++++++++++++++++++++++++++++++++++++++++++
data/osinfo/meson.build | 1 +
data/recommended-downloads.xml | 1 +
src/installed-media.vala | 14 ++++++++++++--
4 files changed, 57 insertions(+), 2 deletions(-)
---
diff --git a/data/osinfo/gnome-nightly.xml b/data/osinfo/gnome-nightly.xml
new file mode 100644
index 00000000..a97595a1
--- /dev/null
+++ b/data/osinfo/gnome-nightly.xml
@@ -0,0 +1,43 @@
+<libosinfo version="0.0.1">
+<!-- Licensed under the GNU General Public License version 2 or later.
+ See http://www.gnu.org/licenses/ for a copy of the license text -->
+ <os id="http://gnome.org/gnome/nightly">
+ <short-id>gnomenightly</short-id>
+ <name>GNOME</name>
+ <version>Nightly</version>
+ <vendor>The GNOME Project</vendor>
+ <family>linux</family>
+ <distro>gnome</distro>
+
+ <firmware arch="x86_64" type="efi"/>
+
+ <devices>
+ <device id="http://pcisig.com/pci/1af4/1050"/> <!-- virtio1.0-gpu -->
+ <device id="http://qemu.org/chipset/x86/q35"/> <!-- qemu-x86-q35 -->
+ </devices>
+
+ <variant id="nightly">
+ <name>GNOME Nightly</name>
+ </variant>
+
+ <media arch="x86_64" format="qcow2">
+ <variant id="nightly"/>
+ <url>https://feborg.es/gnome-nightly/</url>
+ </media>
+
+ <resources arch="all">
+ <minimum>
+ <n-cpus>1</n-cpus>
+ <cpu>1000000000</cpu>
+ <ram>1073741824</ram>
+ <storage>10737418240</storage>
+ </minimum>
+
+ <recommended>
+ <ram>3147483648</ram>
+ <storage>21474836480</storage>
+ </recommended>
+ </resources>
+
+ </os>
+</libosinfo>
diff --git a/data/osinfo/meson.build b/data/osinfo/meson.build
index cefb43ac..80c1dc21 100644
--- a/data/osinfo/meson.build
+++ b/data/osinfo/meson.build
@@ -5,6 +5,7 @@ osinfo_db = [
['eos-3.3.xml', 'gnome-boxes/osinfo/os/endlessos.com'],
['fedora-1.xml', 'gnome-boxes/osinfo/os/fedoraproject.org'],
['freedos-1.2.xml', 'gnome-boxes/osinfo/os/freedos.org'],
+ ['gnome-nightly.xml', 'osinfo/os/gnome.org'],
['opensuse-10.2.xml', 'gnome-boxes/osinfo/os/opensuse.org'],
['ubuntu-4.10.xml', 'gnome-boxes/osinfo/os/ubuntu.com'],
['popos-17.10.xml', 'gnome-boxes/osinfo/os/system76.com'],
diff --git a/data/recommended-downloads.xml b/data/recommended-downloads.xml
index 827da8e6..26612393 100644
--- a/data/recommended-downloads.xml
+++ b/data/recommended-downloads.xml
@@ -9,6 +9,7 @@
available.
-->
<list>
+ <os_id>http://gnome.org/gnome/nightly</os_id>
<os_id>http://redhat.com/rhel/8.1</os_id>
<os_id>http://fedoraproject.org/fedora/31</os_id>
<os_id>http://fedoraproject.org/silverblue/31</os_id>
diff --git a/src/installed-media.vala b/src/installed-media.vala
index 6a3ac5e3..04497851 100644
--- a/src/installed-media.vala
+++ b/src/installed-media.vala
@@ -12,7 +12,8 @@
".vdi", ".vdi.gz",
".vmdk", ".vmdk.gz",
".vpc", ".vpc.gz",
- ".cloop", ".cloop.gz" };
+ ".cloop", ".cloop.gz",
+ "gnome-nightly" };
public const string[] supported_architectures = {
"i686", "i586", "i486", "i386", "x86_64", "amd64"
};
@@ -24,7 +25,7 @@
protected override string? architecture {
owned get {
// Many distributors provide arch name on the image file so lets try to use that if possible
- if (device_file.contains ("amd64") || device_file.contains ("x86_64"))
+ if (device_file.contains ("amd64") || device_file.contains ("x86_64") || device_file.contains
("gnome-nightly"))
return "x86_64";
else {
foreach (var arch in supported_architectures) {
@@ -62,6 +63,15 @@ public InstalledMedia (string path, bool known_qcow2 = false) throws GLib.Error
public async InstalledMedia.guess_os (string path, MediaManager media_manager) throws GLib.Error {
this (path);
+ if (path.contains ("gnome-nightly")) {
+ try {
+ os = yield media_manager.os_db.get_os_by_id ("http://gnome.org/gnome/nightly");
+ os_media = os.get_media_list ().get_nth (0) as Osinfo.Media;
+ } catch (OSDatabaseError.UNKNOWN_OS_ID error) {
+ print ("\n\n\n\n\n\n\n %s\n\n\n", error.message);
+ }
+ }
+
resources = OSDatabase.get_default_resources ();
label_setup ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]