[gnome-dictionary] build: Validate desktop and appdata files
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-dictionary] build: Validate desktop and appdata files
- Date: Wed, 23 Aug 2017 09:40:27 +0000 (UTC)
commit 45d626b8efb2d566cec7546626d2365c6bc1a9b0
Author: Emmanuele Bassi <ebassi gnome org>
Date: Thu Aug 10 10:52:39 2017 +0100
build: Validate desktop and appdata files
We want to ensure that any change to the desktop and appdata files won't
break them, and Meson makes it easy for us to do so.
data/meson.build | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
---
diff --git a/data/meson.build b/data/meson.build
index a22eaf6..3653142 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -6,6 +6,14 @@ i18n.merge_file ('desktop',
po_dir: po_dir,
type: 'desktop')
+desktop_file_validate = find_program('desktop-file-validate', required: false)
+if desktop_file_validate.found()
+ test('validate-desktop',
+ desktop_file_validate,
+ args: 'org.gnome.Dictionary.desktop',
+ workdir: meson.current_build_dir())
+endif
+
i18n.merge_file ('desktop',
input: 'org.gnome.Dictionary.appdata.xml.in',
output: 'org.gnome.Dictionary.appdata.xml',
@@ -13,6 +21,14 @@ i18n.merge_file ('desktop',
install_dir: join_paths(gdict_datadir, 'appdata'),
po_dir: po_dir)
+appstream_util = find_program('appstream-util', required: false)
+if appstream_util.found()
+ test('validate-appdata',
+ appstream_util,
+ args: [ 'validate', '--nonet', 'org.gnome.Dictionary.appdata.xml' ],
+ workdir: meson.current_build_dir())
+endif
+
service_conf = configuration_data ()
service_conf.set ('bindir', gdict_bindir)
configure_file (input: 'org.gnome.Dictionary.service.in',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]