[gnome-nettool/wip/jtojnar/meson-cleanups: 1/6] meson: Format with muon fmt
- From: Jan Tojnar <jtojnar src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-nettool/wip/jtojnar/meson-cleanups: 1/6] meson: Format with muon fmt
- Date: Tue, 27 Sep 2022 09:28:46 +0000 (UTC)
commit bf44fad17da8ab17b8f238225b7c7150cd7213e5
Author: Jan Tojnar <jtojnar gmail com>
Date: Tue Sep 27 04:30:53 2022 +0200
meson: Format with muon fmt
data/meson.build | 49 ++++++++++++++++++++++++++++++-------------------
help/meson.build | 10 ++++++----
meson.build | 36 +++++++++++++++++++++++++-----------
pixmaps/meson.build | 10 ++++++++--
po/meson.build | 5 ++++-
src/meson.build | 11 +++++++----
6 files changed, 80 insertions(+), 41 deletions(-)
---
diff --git a/data/meson.build b/data/meson.build
index ed1e8bb..4196c0f 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -11,28 +11,39 @@ cdata.set_quoted('GNOME_NETTOOL_LOCALEDIR', join_paths(prefix, localedir))
cdata.set_quoted('PIXMAPS_DIR', pixmaps_dir)
cdata.set_quoted('UI_DIR', ui_dir)
-install_data('gnome-nettool.ui', install_dir: ui_dir)
+install_data(
+ 'gnome-nettool.ui',
+ install_dir: ui_dir,
+)
desktop_conf = configuration_data()
desktop_conf.set('PACKAGE_VERSION', meson.project_version())
-desktop_in = configure_file(input: 'gnome-nettool.desktop.in.in',
- output: 'gnome-nettool.desktop.in',
- configuration: desktop_conf)
-
-i18n.merge_file(type: 'desktop',
- input: desktop_in,
- output: 'gnome-nettool.desktop',
- po_dir: po_dir,
- install: true,
- install_dir: join_paths(prefix, datadir, 'applications'))
-
-i18n.merge_file(type: 'xml',
- input: 'gnome-nettool.appdata.xml.in',
- output: 'gnome-nettool.appdata.xml',
- po_dir: po_dir,
- install: true,
- install_dir: join_paths(prefix, datadir, 'metainfo'),
+desktop_in = configure_file(
+ input: 'gnome-nettool.desktop.in.in',
+ output: 'gnome-nettool.desktop.in',
+ configuration: desktop_conf,
+)
+
+i18n.merge_file(
+ type: 'desktop',
+ input: desktop_in,
+ output: 'gnome-nettool.desktop',
+ po_dir: po_dir,
+ install: true,
+ install_dir: join_paths(prefix, datadir, 'applications'),
)
-install_data('org.gnome.gnome-nettool.gschema.xml', install_dir: schemas_dir)
+i18n.merge_file(
+ type: 'xml',
+ input: 'gnome-nettool.appdata.xml.in',
+ output: 'gnome-nettool.appdata.xml',
+ po_dir: po_dir,
+ install: true,
+ install_dir: join_paths(prefix, datadir, 'metainfo'),
+)
+
+install_data(
+ 'org.gnome.gnome-nettool.gschema.xml',
+ install_dir: schemas_dir,
+)
diff --git a/help/meson.build b/help/meson.build
index 786c878..b928397 100644
--- a/help/meson.build
+++ b/help/meson.build
@@ -12,7 +12,9 @@ media = [
'figures/gnome-nettool.png',
]
-gnome.yelp(meson.project_name(),
- sources: sources,
- media: media,
- symlink_media: true)
+gnome.yelp(
+ meson.project_name(),
+ sources: sources,
+ media: media,
+ symlink_media: true,
+)
diff --git a/meson.build b/meson.build
index eb3ff23..afe3482 100644
--- a/meson.build
+++ b/meson.build
@@ -1,11 +1,14 @@
-project('gnome-nettool', 'c',
- version: '42.0',
- default_options: [
- 'buildtype=debugoptimized',
- 'warning_level=1',
- ],
- meson_version: '>= 0.40.1',
- license: 'GPLv2.0+')
+project(
+ 'gnome-nettool',
+ 'c',
+ version: '42.0',
+ default_options: [
+ 'buildtype=debugoptimized',
+ 'warning_level=1',
+ ],
+ meson_version: '>= 0.40.1',
+ license: 'GPLv2.0+',
+)
gio_req = '>= 2.26'
gtk_req = '>= 3.0.0'
@@ -29,7 +32,10 @@ config_inc = include_directories('.')
# Check headers
cdata.set('HAVE_SYS_SOCKIO_H', cc.has_header('sys/sockio.h'))
-req_headers = ['sys/socket.h', 'ifaddrs.h']
+req_headers = [
+ 'sys/socket.h',
+ 'ifaddrs.h',
+]
foreach req_header : req_headers
if not cc.has_header(req_header)
error('Required header not found: ' + req_header)
@@ -41,7 +47,12 @@ gio_dep = dependency('gio-2.0', version: gio_req)
gtop_dep = dependency('libgtop-2.0')
gmodule_dep = dependency('gmodule-export-2.0')
-nettool_deps = [gtk_dep, gio_dep, gmodule_dep, gtop_dep]
+nettool_deps = [
+ gtk_dep,
+ gio_dep,
+ gmodule_dep,
+ gtop_dep,
+]
po_dir = join_paths(meson.source_root(), 'po')
@@ -52,6 +63,9 @@ subdir('help')
subdir('pixmaps')
# write config.h
-configure_file(output: 'config.h', configuration: cdata)
+configure_file(
+ output: 'config.h',
+ configuration: cdata,
+)
meson.add_install_script('postinstall.py')
diff --git a/pixmaps/meson.build b/pixmaps/meson.build
index e20a605..2d30950 100644
--- a/pixmaps/meson.build
+++ b/pixmaps/meson.build
@@ -9,7 +9,10 @@ pixmaps = [
'wavelan-16.png',
]
pixmaps_dir = join_paths(prefix, datadir, pkg, 'pixmaps')
-install_data(pixmaps, install_dir: pixmaps_dir)
+install_data(
+ pixmaps,
+ install_dir: pixmaps_dir,
+)
icons = [
['16x16', files('icons/16x16/apps/gnome-nettool.png')],
@@ -24,5 +27,8 @@ foreach icon : icons
size = icon[0]
file = icon[1]
iconsdir = join_paths(prefix, datadir, 'icons', 'hicolor', size, 'apps')
- install_data(file, install_dir: iconsdir)
+ install_data(
+ file,
+ install_dir: iconsdir,
+ )
endforeach
diff --git a/po/meson.build b/po/meson.build
index 192e262..0b1efd5 100644
--- a/po/meson.build
+++ b/po/meson.build
@@ -1,3 +1,6 @@
i18n = import('i18n')
-i18n.gettext('gnome-nettool', preset : 'glib')
+i18n.gettext(
+ 'gnome-nettool',
+ preset: 'glib',
+)
diff --git a/src/meson.build b/src/meson.build
index 0dd9e8b..2af2b16 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -15,7 +15,10 @@ nettool_sources = [
'main.c',
]
-executable('gnome-nettool', nettool_sources,
- include_directories: config_inc,
- dependencies: nettool_deps,
- install: true)
+executable(
+ 'gnome-nettool',
+ nettool_sources,
+ include_directories: config_inc,
+ dependencies: nettool_deps,
+ install: true,
+)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]