Add flatpak metadata and improve meson system

This commit is contained in:
Bnyro
2023-06-26 13:32:03 +02:00
parent eb8a01c27e
commit 7494340afb
11 changed files with 88 additions and 17 deletions

View File

@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<schemalist>
<schema path="/com/lemmygtk/lemoa" id="@BASE_ID@">
</schema>
</schemalist>

View File

@@ -0,0 +1,45 @@
<?xml version="1.0" encoding="UTF-8"?>
<component type="desktop-application">
<id>@BASE_ID@</id>
<metadata_license>CC0</metadata_license>
<project_license>GPL-3.0</project_license>
<name>@NAME@</name>
<summary>Gtk client for Lemmy</summary>
<description>
<p>A native Gtk client for the Lemmyverse</p>
</description>
<screenshots>
<screenshot type="default">
<image>https://raw.githubusercontent.com/lemmy-gtk/lemoa/main/data/screenshots/posts.png</image>
<caption>Posts view</caption>
</screenshot>
<screenshot>
<image>https://raw.githubusercontent.com/lemmy-gtk/lemoa/main/data/screenshots/community.png</image>
<caption>Community view</caption>
</screenshot>
</screenshots>
<url type="homepage">https://github.com/lemmy-gtk/lemoa</url>
<url type="bugtracker">https://github.com/lemmy-gtk/lemoa/issues</url>
<content_rating type="oars-1.0" />
<releases>
<release version="0.1.0" date="2023-06-26">
<description>
<ul>
<li>Initial release</li>
</ul>
</description>
</release>
</releases>
<kudos>
<!--
GNOME Software kudos:
https://gitlab.gnome.org/GNOME/gnome-software/blob/master/doc/kudos.md
-->
<kudo>ModernToolkit</kudo>
<kudo>HiDpiIcon</kudo>
</kudos>
<developer_name>Bnyro</developer_name>
<update_contact>bnyro@tutanota.com</update_contact>
<launchable type="desktop-id">@app-id@.desktop</launchable>
<platform>GTK 4</platform>
</component>

View File

Before

Width:  |  Height:  |  Size: 5.0 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

View File

Before

Width:  |  Height:  |  Size: 5.8 KiB

After

Width:  |  Height:  |  Size: 5.8 KiB

13
data/icons/meson.build Normal file
View File

@@ -0,0 +1,13 @@
# Scalable icon
install_data(
'@0@.svg'.format(base_id),
install_dir: iconsdir / 'hicolor' / 'scalable' / 'apps',
rename: '@0@.svg'.format(application_id)
)
# Symbolic icon
install_data(
'@0@-symbolic.svg'.format(base_id),
install_dir: iconsdir / 'hicolor' / 'symbolic' / 'apps',
rename: '@0@-symbolic.svg'.format(application_id)
)

View File

@@ -2,6 +2,7 @@ desktop_conf = configuration_data()
desktop_conf.set('NAME', meson.project_name())
desktop_conf.set('ICON', application_id)
desktop_conf.set('APP_ID', application_id)
desktop_conf.set('BASE_ID', base_id)
desktop_conf.set('EXEC', meson.project_name())
# Desktop file
@@ -10,19 +11,24 @@ configure_file(
output: '@BASENAME@',
install: true,
configuration: desktop_conf,
install_dir: applicationsdir
install_dir: metainfodir
)
# Scalable icon
install_data(
'@0@.svg'.format(base_id),
install_dir: iconsdir / 'hicolor' / 'scalable' / 'apps',
rename: '@0@.svg'.format(application_id)
# Metainfo file
configure_file(
input: '@0@.metainfo.xml.in'.format(base_id),
output: '@BASENAME@',
install: true,
configuration: desktop_conf,
install_dir: metainfodir
)
# Symbolic icon
install_data(
'@0@-symbolic.svg'.format(base_id),
install_dir: iconsdir / 'hicolor' / 'symbolic' / 'apps',
rename: '@0@-symbolic.svg'.format(application_id)
configure_file(
input: '@0@.gschema.xml.in'.format(base_id),
output: '@0@.gschema.xml'.format(application_id),
configuration: desktop_conf,
install: true,
install_dir: datadir / 'glib-2.0' / 'schemas'
)
subdir('icons')