[gnome-software/wip/ubuntu-3-20: 21/57] trivial: Allow arbitrary variables to be read from /etc/os-release
- From: Robert Ancell <rancell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/ubuntu-3-20: 21/57] trivial: Allow arbitrary variables to be read from /etc/os-release
- Date: Thu, 5 Oct 2017 04:12:11 +0000 (UTC)
commit 56fc49430e372eeca8b08887a33258dba4513667
Author: Robert Ancell <robert ancell canonical com>
Date: Thu Feb 11 15:31:30 2016 +1300
trivial: Allow arbitrary variables to be read from /etc/os-release
src/gs-os-release.c | 6 ++++++
src/gs-os-release.h | 2 ++
2 files changed, 8 insertions(+), 0 deletions(-)
---
diff --git a/src/gs-os-release.c b/src/gs-os-release.c
index 9c639af..b15d0f0 100644
--- a/src/gs-os-release.c
+++ b/src/gs-os-release.c
@@ -126,4 +126,10 @@ gs_os_release_get_pretty_name (GError **error)
return gs_os_release_parse_variable ("PRETTY_NAME", error);
}
+gchar *
+gs_os_release_get (const gchar *name, GError **error)
+{
+ return gs_os_release_parse_variable (name, error);
+}
+
/* vim: set noexpandtab: */
diff --git a/src/gs-os-release.h b/src/gs-os-release.h
index cc9b7c7..6eaffa4 100644
--- a/src/gs-os-release.h
+++ b/src/gs-os-release.h
@@ -39,6 +39,8 @@ gchar *gs_os_release_get_version (GError **error);
gchar *gs_os_release_get_id (GError **error);
gchar *gs_os_release_get_version_id (GError **error);
gchar *gs_os_release_get_pretty_name (GError **error);
+gchar *gs_os_release_get (const gchar *name,
+ GError **error);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]