# HG changeset patch # User Ludovic Chabant # Date 1483548678 28800 # Node ID c6d28a830f68829bd44dc8762cd2d6c9f8e888b4 # Parent 2cea36073188fac7219cf728baaaf84ef7bf0838 Add PyPI support. diff -r 2cea36073188 -r c6d28a830f68 .hgignore --- a/.hgignore Wed Jan 04 08:46:27 2017 -0800 +++ b/.hgignore Wed Jan 04 08:51:18 2017 -0800 @@ -2,6 +2,10 @@ __pycache__ venv .cache +.eggs .sass-cache *.css.map *.pyc + +Fontaine.egg-info +fontaine/version.py diff -r 2cea36073188 -r c6d28a830f68 fontaine/__init__.py --- a/fontaine/__init__.py Wed Jan 04 08:46:27 2017 -0800 +++ b/fontaine/__init__.py Wed Jan 04 08:51:18 2017 -0800 @@ -0,0 +1,4 @@ +try: + from .version import version +except ImportError: + version = '' diff -r 2cea36073188 -r c6d28a830f68 setup.cfg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/setup.cfg Wed Jan 04 08:51:18 2017 -0800 @@ -0,0 +1,2 @@ +[aliases] +test=pytest diff -r 2cea36073188 -r c6d28a830f68 setup.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/setup.py Wed Jan 04 08:51:18 2017 -0800 @@ -0,0 +1,42 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- + +import os.path +from setuptools import setup, find_packages + + +def read(fname): + with open(os.path.join(os.path.dirname(__file__), fname)) as fp: + return fp.read() + + +def readlines(fname): + return [l.strip() for l in read(fname).strip().splitlines()] + + +install_requires = readlines('requirements.txt') +tests_require = readlines('dev-requirements.txt') +long_description = read('README.rst') + + +setup( + name="Fontaine", + use_scm_version={'write_to': 'fontaine/version.py'}, + description="A library for parsing and rendering Fountain screenplays.", + long_description=long_description, + author="Ludovic Chabant", + author_email="ludovic@chabant.com", + license="Apache License 2.0", + url="https://bolt80.com/fontaine", + keywords='fountain screenplay screenwriting screenwriter', + packages=find_packages(), + include_package_data=True, + zip_safe=False, + setup_requires=['setuptools_scm', 'pytest-runner'], + tests_require=tests_require, + install_requires=install_requires, + entry_points={ + 'console_scripts': [ + 'fontaine = fontaine.cli.main' + ]} +)