Skip to content
Permalink
Browse files

packaging: setup conditional dependencies

Signed-off-by: Florian Scherf <f.scherf@pengutronix.de>
  • Loading branch information...
fscherf committed Feb 17, 2019
1 parent 272adba commit ac2ae6fe2f337780856b46e49dcab5ac5eec2ebc
Showing with 43 additions and 10 deletions.
  1. +4 −0 Makefile
  2. +1 −2 REQUIREMENTS.dev.txt
  3. +12 −2 flamingo/plugins/__init__.py
  4. +26 −6 setup.py
@@ -28,3 +28,7 @@ edit: env
shell: env
. $(PYTHON_VENV)/bin/activate && \
ipython

freeze: env
. $(PYTHON_VENV)/bin/activate && \
pip freeze
@@ -1,4 +1,3 @@
-e .
-e .[full]
tox
flake8
ipython==6
@@ -1,14 +1,24 @@
from .rst.bootstrap3 import rstBootstrap3 # NOQA
from .rst.base import reStructuredText # NOQA
from .rst.pygments import rstPygments # NOQA
from .rst.image import rstImage # NOQA
from .rst.file import rstFile # NOQA
from .redirects import Redirects # NOQA
from .authors import Authors # NOQA
from .layers import Layers # NOQA
from .feeds import Feeds # NOQA
from .html import HTML # NOQA
from .i18n import I18N # NOQA
from .tags import Tags # NOQA
from .time import Time # NOQA
from .ini import INI # NOQA

try:
from .rst.pygments import rstPygments # NOQA

except ImportError:
pass

try:
from .feeds import Feeds # NOQA

except ImportError:
pass
@@ -4,6 +4,30 @@
from setuptools import setup, find_packages
import flamingo

EXTRAS_REQUIRE = {
'live-server': [
'aiohttp-json-rpc==0.12',
'aionotify==0.2.0',
],
'chardet': [
'chardet',
],
'pygments': [
'pygments',
],
'feeds': [
'feedgen==0.7.0',
],
'coloredlogs': [
'coloredlogs',
],
'ipython': [
'ipython',
]
}

EXTRAS_REQUIRE['full'] = sum([v for k, v in EXTRAS_REQUIRE.items()], [])

setup(
include_package_data=True,
name='flamingo',
@@ -16,11 +40,6 @@
install_requires=[
'jinja2',
'docutils',
'aiohttp-json-rpc',
'aionotify',
'coloredlogs',
'pygments',
'feedgen',
],
scripts=[
'bin/flamingo',
@@ -32,5 +51,6 @@
'pytest11': [
'flamingo = flamingo.pytest',
],
}
},
extras_require=EXTRAS_REQUIRE,
)

0 comments on commit ac2ae6f

Please sign in to comment.
You can’t perform that action at this time.