Skip to content

Commit

Permalink
Merge pull request #624 from sabriunal/fix-appcli
Browse files Browse the repository at this point in the history
Appdata related paches
  • Loading branch information
maoschanz authored Nov 2, 2023
2 parents add8940 + 5a51c80 commit 00ea158
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 9 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ options, the right building tools, and luck.
- `meson`. The version of meson required by the `meson.build` file at the root
of the project can be changed if necessary, but please don't add this change to
your commit(s).
- [optional] `appstream-util` (validation of the `.appdata.xml` file)
- [optional] `appstreamcli` (validation of the `.appdata.xml` file)
- `libglib2.0-dev-bin` (IIRC that one is to compress the `.ui` files and the
icons into a `.gresource` file: 100% necessary)
- [optional] `itstool` (to generate translation files for the help manual)
Expand Down
2 changes: 1 addition & 1 deletion com.github.maoschanz.drawing.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"app-id" : "com.github.maoschanz.drawing",
"runtime" : "org.gnome.Platform",
"runtime-version" : "44",
"runtime-version" : "45",
"sdk" : "org.gnome.Sdk",
"command" : "drawing",
"finish-args" : [
Expand Down
11 changes: 11 additions & 0 deletions data/com.github.maoschanz.drawing.appdata.xml.in
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,17 @@
<p>Supported file types include PNG, JPEG and BMP.</p>
</description>

<categories>
<category>Graphics</category>
</categories>

<keywords>
<keyword translate="no">drawing</keyword>
<keyword>Paint</keyword>
<keyword>Sketch</keyword>
<keyword>Pencil</keyword>
</keywords>

<releases>
<release version="1.2.0" date="2023-04-29">
<!-- TODO actual date -->
Expand Down
11 changes: 4 additions & 7 deletions data/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -38,16 +38,13 @@ if get_option('enable-translations-and-appdata')
install_dir: join_paths(get_option('datadir'), 'metainfo')
)

appstream_util = find_program('appstream-util', required: false)
if appstream_util.found()
appstreamcli = find_program('appstreamcli', required: false)
if appstreamcli.found()
test(
'Validate appstream file',
appstream_util,
args: ['validate', appstream_file]
appstreamcli,
args: ['validate', '--no-net', appstream_file]
)
# The app will never pass "validate-strict" because appstream-util wants
# pictures with a 16:9 ratio, while i use pictures of the default window
# size, which is approximating the objectively better golden ratio.
endif
endif

Expand Down

0 comments on commit 00ea158

Please sign in to comment.