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