[gnome-builder/gnome-builder-3-20] autotools-templates: allow resource:// for sources
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/gnome-builder-3-20] autotools-templates: allow resource:// for sources
- Date: Sat, 14 May 2016 12:48:07 +0000 (UTC)
commit c44ca0fc4bdd58836263ea3ee11f320af8f1603b
Author: Christian Hergert <chergert redhat com>
Date: Fri May 13 16:21:08 2016 +0300
autotools-templates: allow resource:// for sources
.../autotools_templates/__init__.py | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/plugins/autotools-templates/autotools_templates/__init__.py
b/plugins/autotools-templates/autotools_templates/__init__.py
index 62c4ed6..f61cc8b 100644
--- a/plugins/autotools-templates/autotools_templates/__init__.py
+++ b/plugins/autotools-templates/autotools_templates/__init__.py
@@ -167,9 +167,12 @@ class AutotoolsTemplate(Ide.TemplateBase, Ide.ProjectTemplate):
self.prepare_file_modes(modes)
for src,dst in files.items():
- path = get_module_data_path(src)
destination = directory.get_child(dst % expands)
- self.add_path(path, destination, scope, modes.get(src, 0))
+ if src.startswith("resource://"):
+ self.add_resource(src, destination, scope, modes.get(src, 0))
+ else:
+ path = get_module_data_path(src)
+ self.add_path(path, destination, scope, modes.get(src, 0))
self.expand_all_async(cancellable, self.expand_all_cb, task)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]