Skip to content

Commit

Permalink
Add an AppStream file
Browse files Browse the repository at this point in the history
  • Loading branch information
zefr0x committed Nov 20, 2023
1 parent 596b9a8 commit b07272b
Show file tree
Hide file tree
Showing 2 changed files with 67 additions and 0 deletions.
52 changes: 52 additions & 0 deletions me.jtheoof.swappy.metainfo.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
<?xml version="1.0" encoding="utf-8"?>
<component type="desktop">
<id>me.jtheoof.swappy</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>MIT</project_license>
<name>swappy</name>
<summary>Wayland native snapshot editing tool, inspired by Snappy on macOS</summary>
<description>
<p>A Wayland native snapshot and image editing tool, inspired by Snappy on macOS. Works great with grim, slurp and sway. But can easily work with other screen copy tools that can output a final image to stdout.</p>
</description>
<categories>
<category>Utility</category>
<category>Graphics</category>
</categories>
<keywords>
<keyword>wayland</keyword>
<keyword>snapshot</keyword>
<keyword>annotation</keyword>
<keyword>editing</keyword>
</keywords>
<content_rating type="oars-1.1" />
<url type="homepage">https://github.com/jtheoof/swappy</url>
<url type="help">https://github.com/jtheoof/swappy</url>
<url type="bugtracker">https://github.com/jtheoof/swappy/issues</url>
<url type="translate">https://github.com/jtheoof/swappy?tab=readme-ov-file#i18n</url>
<url type="vcs-browser">https://github.com/jtheoof/swappy</url>
<url type="contribute">https://github.com/jtheoof/swappy?tab=readme-ov-file#contributing</url>
<provides>
<binary>swappy</binary>
<mediatype>image/png</mediatype>
<mediatype>image/jpeg</mediatype>
</provides>
<developer id="io.github.jtheoof">
<name>Jeremy Attali</name>
<url>https://github.com/jtheoof</url>
</developer>
<screenshots>
<screenshot type="default">
<image type="source" width="1347" height="672">https://raw.githubusercontent.com/jtheoof/swappy/596b9a8b17234303a9d4d2ea1d3107cb5442253e/docs/images/screenshot-1.0.0.png</image>
</screenshot>
</screenshots>
<branding>
<color type="primary" scheme_preference="light">#008080</color>
<color type="primary" scheme_preference="dark">#f78a00</color>
</branding>
<releases>
<release version="1.5.1" date="2022-11-20" urgency="low">
<url>https://github.com/jtheoof/swappy/blob/master/CHANGELOG.md#151-2022-11-20</url>
</release>
</releases>
<translation type="gettext">swappy</translation>
</component>
15 changes: 15 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ project(
],
)

application_id = 'me.jtheoof.swappy'

version = '"@0@"'.format(meson.project_version())
git = find_program('git', native: true, required: false)
if git.found()
Expand Down Expand Up @@ -42,6 +44,7 @@ pango = dependency('pango')
math = cc.find_library('m')
gtk = dependency('gtk+-3.0', version: '>=3.20.0')
gio = dependency('gio-2.0')
appstream_util = find_program('appstreamcli', required: false)

subdir('res')
subdir('src/po')
Expand Down Expand Up @@ -74,6 +77,18 @@ executable(
install: true,
)

app_data_file ='@0@.metainfo.xml'.format(application_id)
# Validate app data file
if appstream_util.found()
test('Validate app data file', appstream_util,
args: ['validate', app_data_file]
)
endif

# Install app data file
install_data(app_data_file, install_dir: get_option('datadir') + '/metainfo')

# Build man pages
scdoc = find_program('scdoc', required: get_option('man-pages'))

if scdoc.found()
Expand Down

0 comments on commit b07272b

Please sign in to comment.