Fix #95: Add AppData file for package managers

This commit is contained in:
Jon Lund Steffensen
2014-12-15 02:40:14 -05:00
parent dc78015f32
commit 1975e92bc8
3 changed files with 35 additions and 2 deletions
+20 -2
View File
@@ -34,6 +34,9 @@ SYSTEMD_USER_UNIT_IN_FILES = \
data/systemd/redshift.service.in \
data/systemd/redshift-gtk.service.in
APPDATA_IN_FILES = \
data/appdata/redshift-gtk.appdata.xml.in
# Icons
if ENABLE_GUI
@@ -85,6 +88,19 @@ $(systemduserunit_DATA): $(SYSTEMD_USER_UNIT_IN_FILES) Makefile
sed -e "s|\@bindir\@|$(bindir)|g" "$(srcdir)/$(@:.service=.service.in)" > $@
# Appdata file
if ENABLE_GUI
appdatadir = @datadir@/appdata
appdata_DATA = $(APPDATA_IN_FILES:.xml.in=.xml)
# We would preferable use @INTLTOOL_XML_RULE@ here but
# sadly it is broken for out-of-tree builds.
%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*.po)
$(AM_V_GEN)$(MKDIR_P) $(@D);
$(INTLTOOL_V_MERGE)LC_ALL=C $(INTLTOOL_MERGE) $(INTLTOOL_V_MERGE_OPTIONS) -x -u -c $(top_builddir)/po/.intltool-merge-cache $(top_srcdir)/po $< $@
endif
EXTRA_DIST = \
$(EXTRA_ROOTDOC_FILES) \
@@ -92,11 +108,13 @@ EXTRA_DIST = \
$(_UBUNTU_MONO_DARK_FILES) \
$(_UBUNTU_MONO_LIGHT_FILES) \
$(DESKTOP_IN_FILES) \
$(SYSTEMD_USER_UNIT_IN_FILES)
$(SYSTEMD_USER_UNIT_IN_FILES) \
$(APPDATA_IN_FILES)
CLEANFILES = \
$(desktop_DATA) \
$(systemduserunit_DATA)
$(systemduserunit_DATA) \
$(appdata_DATA)
# Update PO translations
+14
View File
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2014 Jon Lund Steffensen <jonlst@gmail.com> -->
<application>
<id type="desktop">redshift-gtk.desktop</id>
<metadata_license>CC0</metadata_license>
<project_license>GPL-3.0+</project_license>
<description>
<_p>Redshift adjusts the color temperature of your screen according to your surroundings. This may help your eyes hurt less if you are working in front of the screen at night.</_p>
<_p>The color temperature is set according to the position of the sun. A different color temperature is set during night and daytime. During twilight and early morning, the color temperature transitions smoothly from night to daytime temperature to allow your eyes to slowly adapt.</_p>
<_p>This program provides a status icon that allows the user to control Redshift.</_p>
</description>
<url type="homepage">http://jonls.dk/redshift/</url>
<updatecontact>jonlst@gmail.com</updatecontact>
</application>
+1
View File
@@ -1,5 +1,6 @@
# List of source files containing translatable strings
data/appdata/redshift-gtk.appdata.xml.in
data/applications/redshift-gtk.desktop.in
src/redshift.c