feat: use app_id instead of hardcoded id
This commit is contained in:
parent
4adf42c27b
commit
fd41349aa6
|
@ -1,13 +1,12 @@
|
|||
application_id = 'io.github.Bavarder.Bavarder'
|
||||
|
||||
scalable_dir = join_paths('hicolor', 'scalable', 'apps')
|
||||
install_data(
|
||||
join_paths(scalable_dir, ('@0@.svg').format(application_id)),
|
||||
join_paths(scalable_dir, ('@0@.svg').format(APPLICATION_ID)),
|
||||
install_dir: join_paths(get_option('datadir'), 'icons', scalable_dir)
|
||||
)
|
||||
|
||||
symbolic_dir = join_paths('hicolor', 'symbolic', 'apps')
|
||||
install_data(
|
||||
join_paths(symbolic_dir, ('@0@-symbolic.svg').format(application_id)),
|
||||
install_dir: join_paths(get_option('datadir'), 'icons', symbolic_dir)
|
||||
join_paths(symbolic_dir, ('@0@-symbolic.svg').format(PROJECT_RDNN_NAME)),
|
||||
install_dir: join_paths(get_option('datadir'), 'icons', symbolic_dir),
|
||||
rename: '@0@-symbolic.svg'.format(APPLICATION_ID)
|
||||
)
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<component type="desktop">
|
||||
<id>io.github.Bavarder.Bavarder</id>
|
||||
<id>@APP_ID@</id>
|
||||
<name>Bavarder</name>
|
||||
<summary>Chit-chat with an AI</summary>
|
||||
<developer_name>0xMRTT</developer_name>
|
||||
<metadata_license>CC0-1.0</metadata_license>
|
||||
<project_license>GPL-3.0-or-later</project_license>
|
||||
<launchable type="desktop-id">io.github.Bavarder.Bavarder.desktop</launchable>
|
||||
<launchable type="desktop-id">@APP_ID@.desktop</launchable>
|
||||
<content_rating type="oars-1.1"/>
|
||||
|
||||
<description>
|
||||
|
@ -24,10 +24,10 @@
|
|||
</screenshot>
|
||||
</screenshots>
|
||||
|
||||
<url type="bugtracker">https://codeberg.org/Bavarder/Bavarder/issues</url>
|
||||
<url type="translate">https://translate.codeberg.org/engage/bavarder/</url>
|
||||
<url type="help">https://codeberg.org/Bavarder/Bavarder/issues</url>
|
||||
<url type="homepage">https://bavarder.codeberg.page</url>
|
||||
<url type="homepage">@PROJECT_URL@</url>
|
||||
<url type="bugtracker">@BUGTRACKER_URL@</url>
|
||||
<url type="help">@HELP_URL@</url>
|
||||
<url type="translate">@TRANSLATE_URL@</url>
|
||||
|
||||
<kudos>
|
||||
<kudo>HiDpiIcon</kudo>
|
|
@ -1,7 +1,7 @@
|
|||
[Desktop Entry]
|
||||
Name=Bavarder
|
||||
Exec=bavarder
|
||||
Icon=io.github.Bavarder.Bavarder
|
||||
Icon=@APP_ID@
|
||||
Terminal=false
|
||||
Type=Application
|
||||
Categories=GTK;
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<schemalist gettext-domain="bavarder">
|
||||
<schema id="io.github.Bavarder.Bavarder" path="/io/github/Bavarder/Bavarder/">
|
||||
<schema id="@APP_ID@" path="/io/github/Bavarder/Bavarder/">
|
||||
<key name="width" type="i">
|
||||
<default>350</default>
|
||||
</key>
|
|
@ -3,51 +3,73 @@ pkgdatadir = join_paths(get_option('prefix'), get_option('datadir'), meson.proje
|
|||
|
||||
subdir('ui')
|
||||
|
||||
desktop_file = i18n.merge_file(
|
||||
input: configure_file(
|
||||
input: '@0@.desktop.in.in'.format(PROJECT_RDNN_NAME),
|
||||
output: '@BASENAME@',
|
||||
configuration: conf
|
||||
),
|
||||
output: '@0@.desktop'.format(APPLICATION_ID),
|
||||
type: 'desktop',
|
||||
po_dir: '../po',
|
||||
install: true,
|
||||
install_dir: join_paths(get_option('datadir'), 'applications')
|
||||
)
|
||||
|
||||
desktop_utils = find_program('desktop-file-validate', required: false)
|
||||
if desktop_utils.found()
|
||||
test('Validate desktop file', desktop_utils,
|
||||
args: [desktop_file.full_path()]
|
||||
)
|
||||
endif
|
||||
|
||||
gnome.compile_resources('bavarder',
|
||||
'bavarder.gresource.xml',
|
||||
gresource_bundle: true,
|
||||
source_dir: meson.current_build_dir(),
|
||||
install: true,
|
||||
install_dir: pkgdatadir,
|
||||
dependencies: blueprints,
|
||||
install_dir: PKGDATA_DIR,
|
||||
dependencies: blueprints
|
||||
)
|
||||
|
||||
desktop_file = i18n.merge_file(
|
||||
input: 'io.github.Bavarder.Bavarder.desktop.in',
|
||||
output: 'io.github.Bavarder.Bavarder.desktop',
|
||||
type: 'desktop',
|
||||
po_dir: '../po',
|
||||
install: true,
|
||||
install_dir: join_paths(get_option('datadir'), 'applications')
|
||||
)
|
||||
|
||||
desktop_utils = find_program('desktop-file-validate', required: false)
|
||||
if desktop_utils.found()
|
||||
test('Validate desktop file', desktop_utils, args: [desktop_file])
|
||||
endif
|
||||
|
||||
appstream_file = i18n.merge_file(
|
||||
input: 'io.github.Bavarder.Bavarder.appdata.xml.in',
|
||||
output: 'io.github.Bavarder.Bavarder.appdata.xml',
|
||||
po_dir: '../po',
|
||||
install: true,
|
||||
input: configure_file(
|
||||
input: '@0@.appdata.xml.in.in'.format(PROJECT_RDNN_NAME),
|
||||
output: '@BASENAME@',
|
||||
configuration: configuration_data({
|
||||
'APP_ID': APPLICATION_ID,
|
||||
'PROJECT_URL': PROJECT_URL,
|
||||
'BUGTRACKER_URL': BUGTRACKER_URL,
|
||||
'HELP_URL': HELP_URL,
|
||||
'TRANSLATE_URL': TRANSLATE_URL
|
||||
})
|
||||
),
|
||||
output: '@0@.appdata.xml'.format(APPLICATION_ID),
|
||||
po_dir: '../po',
|
||||
install: true,
|
||||
install_dir: join_paths(get_option('datadir'), 'appdata')
|
||||
)
|
||||
|
||||
appstream_util = find_program('appstream-util', required: false)
|
||||
if appstream_util.found()
|
||||
test('Validate appstream file', appstream_util, args: ['validate', appstream_file])
|
||||
test('Validate appstream file', appstream_util,
|
||||
args: ['validate', appstream_file.full_path()]
|
||||
)
|
||||
endif
|
||||
|
||||
install_data('io.github.Bavarder.Bavarder.gschema.xml',
|
||||
configure_file(
|
||||
input: '@0@.gschema.xml.in'.format(PROJECT_RDNN_NAME),
|
||||
output: '@0@.gschema.xml'.format(APPLICATION_ID),
|
||||
configuration: conf,
|
||||
install: true,
|
||||
install_dir: join_paths(get_option('datadir'), 'glib-2.0/schemas')
|
||||
)
|
||||
|
||||
compile_schemas = find_program('glib-compile-schemas', required: false)
|
||||
if compile_schemas.found()
|
||||
test('Validate schema file',
|
||||
compile_schemas,
|
||||
args: ['--strict', '--dry-run', meson.current_source_dir()])
|
||||
test('Validate schema file', compile_schemas,
|
||||
args: ['--strict', '--dry-run', meson.current_source_dir()]
|
||||
)
|
||||
endif
|
||||
|
||||
subdir('icons')
|
||||
|
|
Loading…
Reference in New Issue