[gnome-builder/wip/gtk4-port: 1111/1774] plugins/flatpak: add x_run_args getter
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/wip/gtk4-port: 1111/1774] plugins/flatpak: add x_run_args getter
- Date: Mon, 11 Jul 2022 22:31:35 +0000 (UTC)
commit 121f0e9d84f4c1d675fea1f6452192d47baf8d0b
Author: Christian Hergert <chergert redhat com>
Date: Sat May 21 13:18:14 2022 -0700
plugins/flatpak: add x_run_args getter
We will eventually remove the run_opts from IdeConfig, so that they can
be part of the RunCommand objects. This just circumvents routing through
IdeConfig which would quote/unquote so we can use it in the upcoming
run command.
src/plugins/flatpak/gbp-flatpak-manifest.c | 10 ++++++++++
src/plugins/flatpak/gbp-flatpak-manifest.h | 1 +
2 files changed, 11 insertions(+)
---
diff --git a/src/plugins/flatpak/gbp-flatpak-manifest.c b/src/plugins/flatpak/gbp-flatpak-manifest.c
index c0e595a0e..28d5a7212 100644
--- a/src/plugins/flatpak/gbp-flatpak-manifest.c
+++ b/src/plugins/flatpak/gbp-flatpak-manifest.c
@@ -45,6 +45,7 @@ struct _GbpFlatpakManifest
*/
gchar **build_args;
gchar *command;
+ gchar **x_run_args;
gchar **finish_args;
gchar *runtime;
gchar *runtime_version;
@@ -425,6 +426,7 @@ gbp_flatpak_manifest_initable_init (GInitable *initable,
discover_strv_field (root_obj, "build-args", &self->build_args);
discover_strv_field (root_obj, "finish-args", &self->finish_args);
discover_strv_field (root_obj, "sdk-extensions", &self->sdk_extensions);
+ discover_strv_field (root_obj, "x-run-args", &self->x_run_args);
if (discover_strv_as_quoted (root_obj, "x-run-args", &run_args))
ide_config_set_run_opts (IDE_CONFIG (self), run_args);
@@ -1213,3 +1215,11 @@ gbp_flatpak_manifest_get_branch (GbpFlatpakManifest *self)
return self->runtime_version;
}
+
+const char * const *
+gbp_flatpak_manifest_get_x_run_args (GbpFlatpakManifest *self)
+{
+ g_return_val_if_fail (GBP_IS_FLATPAK_MANIFEST (self), NULL);
+
+ return (const char * const *)self->x_run_args;
+}
diff --git a/src/plugins/flatpak/gbp-flatpak-manifest.h b/src/plugins/flatpak/gbp-flatpak-manifest.h
index 320bb1816..80ea5e4d2 100644
--- a/src/plugins/flatpak/gbp-flatpak-manifest.h
+++ b/src/plugins/flatpak/gbp-flatpak-manifest.h
@@ -37,6 +37,7 @@ GFile *gbp_flatpak_manifest_get_file (GbpFlatpakManifest
const gchar *gbp_flatpak_manifest_get_primary_module (GbpFlatpakManifest *self);
const gchar *gbp_flatpak_manifest_get_command (GbpFlatpakManifest *self);
gchar *gbp_flatpak_manifest_get_path (GbpFlatpakManifest *self);
+const gchar * const *gbp_flatpak_manifest_get_x_run_args (GbpFlatpakManifest *self);
const gchar * const *gbp_flatpak_manifest_get_build_args (GbpFlatpakManifest *self);
const gchar * const *gbp_flatpak_manifest_get_finish_args (GbpFlatpakManifest *self);
const gchar * const *gbp_flatpak_manifest_get_sdk_extensions (GbpFlatpakManifest *self);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]