apostrophe/setup.py

81 lines
3.2 KiB
Python
Raw Normal View History

2014-07-06 20:35:24 +00:00
#!/usr/bin/env python3
# -*- Mode: Python; coding: utf-8; indent-tabs-mode: nil; tab-width: 4 -*-
### BEGIN LICENSE
# Copyright (C) 2012, Wolf Vollprecht <w.vollprecht@gmail.com>
2019-04-19 18:06:13 +00:00
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License version 3, as published
2014-07-06 20:35:24 +00:00
# by the Free Software Foundation.
2019-04-19 18:06:13 +00:00
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranties of
# MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
2014-07-06 20:35:24 +00:00
# PURPOSE. See the GNU General Public License for more details.
2019-04-19 18:06:13 +00:00
#
# You should have received a copy of the GNU General Public License along
2014-07-06 20:35:24 +00:00
# with this program. If not, see <http://www.gnu.org/licenses/>.
### END LICENSE
##################################################################################
###################### YOU SHOULD MODIFY ONLY WHAT IS BELOW ######################
##################################################################################
from setuptools import setup
2018-04-04 18:31:54 +00:00
import os
2019-04-19 18:06:13 +00:00
def data_files(basename):
data = os.path.join('.', 'data')
root = os.path.join(data, basename)
extra_files = []
for path, directories, filenames in os.walk(root):
paths = []
2018-04-04 18:31:54 +00:00
for filename in filenames:
paths.append(os.path.join(path, filename))
2019-04-19 18:06:13 +00:00
extra_files.append(('share/uberwriter/data/{}'.format(os.path.relpath(path, data)), paths))
return extra_files
2014-07-06 20:35:24 +00:00
2019-04-19 18:06:13 +00:00
extra_files_ui = data_files('ui')
extra_files_media = data_files('media')
extra_files_scripts = data_files('lua')
2018-04-11 13:31:43 +00:00
2018-04-04 18:31:54 +00:00
setup(
2014-07-06 20:35:24 +00:00
name='uberwriter',
2019-04-17 19:34:49 +00:00
version='2.2.0-beta1',
2014-07-06 20:35:24 +00:00
license='GPL-3',
author='Wolf Vollprecht',
author_email='w.vollprecht@gmail.com',
description='A beautiful, simple and distraction free markdown editor.',
2018-04-04 18:31:54 +00:00
long_description="""UberWriter, beautiful distraction free writing
2019-04-19 18:06:13 +00:00
With UberWriter you get only one thing: An empty textbox, that is to
fill with your ideas. There are no settings, you don't have to choose a
font, it is only for writing.You can use markdown for all your markup
needs. PDF, RTF and HTML are generated with pandoc. For PDF generation it
2018-04-04 18:31:54 +00:00
is also required that you choose to install the texlive-luatex package.""",
url='https://github.com/wolfv/uberwriter/',
2018-04-04 18:31:54 +00:00
# cmdclass={'install': InstallAndUpdateDataDirectory},
2014-07-06 20:35:24 +00:00
package_dir = {
2018-04-04 18:31:54 +00:00
# "": '/opt/uberwriter/'
2014-07-06 20:35:24 +00:00
},
packages=[
2019-04-01 16:00:17 +00:00
"uberwriter.pylocales",
# "uberwriter.pressagio",
"uberwriter",
"po"
2018-04-04 18:31:54 +00:00
# "uberwriter.plugins"
# "uberwriter.plugins.bibtex"
2014-07-06 20:35:24 +00:00
],
include_package_data=True,
2014-07-06 20:35:24 +00:00
package_data={
2019-04-01 16:00:17 +00:00
'uberwriter.pylocales' : ['locales.db'],
},
data_files=[
2019-04-19 18:06:13 +00:00
('bin', ['uberwriter.in']),
('share/applications', ['data/de.wolfvollprecht.UberWriter.desktop']),
('share/metainfo', ['data/de.wolfvollprecht.UberWriter.appdata.xml']),
('share/icons/hicolor/scalable/apps', ['data/media/de.wolfvollprecht.UberWriter.svg']),
2019-04-20 16:24:21 +00:00
('share/icons/hicolor/symbolic/apps', ['data/media/de.wolfvollprecht.UberWriter-symbolic.svg']),
2019-04-19 18:06:13 +00:00
('share/glib-2.0/schemas', ['data/de.wolfvollprecht.UberWriter.gschema.xml']),
*(extra_files_ui + extra_files_media + extra_files_scripts)
2014-10-04 22:18:17 +00:00
]
)