Changeset 352903


Ignore:
Timestamp:
02/23/2017 07:01:44 PM (8 years ago)
Author:
Calum Lind <calumlind+deluge@gmail.com>
Branches:
2.0.x, develop, master
Children:
4df88c
Parents:
f2b77c
git-author:
Matthias Mailänder <matthias@mailaender.name> (02/07/2017 07:18:09 PM)
git-committer:
Calum Lind <calumlind+deluge@gmail.com> (02/23/2017 07:01:44 PM)
Message:

[UI] Add an appdata.xml file

For Linux software gallery integration.

Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • setup.py

    rf2b77c r352903  
    4444
    4545desktop_data = 'deluge/ui/data/share/applications/deluge.desktop'
     46appdata_data = 'deluge/ui/data/share/appdata/deluge.appdata.xml'
    4647
    4748# Variables for setuptools.setup
     
    189190            os.system('C_ALL=C ' + '%s ' * 5 % (intltool_merge, intltool_merge_opts,
    190191                                                po_dir, desktop_in, desktop_data))
     192
     193            # creates the translated appdata.xml file
     194            intltool_merge_opts = '--utf8 --quiet --xml-style'
     195            appdata_in = 'deluge/ui/data/share/appdata/deluge.appdata.xml.in'
     196            print('Creating appdata.xml file: %s' % appdata_data)
     197            os.system('C_ALL=C ' + '%s ' * 5 % (intltool_merge, intltool_merge_opts,
     198                                                po_dir, appdata_in, appdata_data))
    191199
    192200        print('Compiling po files from %s...' % po_dir)
     
    235243            print('Deleting %s' % desktop_data)
    236244            os.remove(desktop_data)
     245        if os.path.isfile(appdata_data):
     246            print('Deleting %s' % appdata_data)
     247            os.remove(appdata_data)
    237248
    238249
     
    416427    if os.path.isfile(desktop_data):
    417428        _data_files.append(('share/applications', [desktop_data]))
     429    if os.path.isfile(appdata_data):
     430        _data_files.append(('share/appdata', [appdata_data]))
    418431
    419432_entry_points['console_scripts'] = [
Note: See TracChangeset for help on using the changeset viewer.