mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-09-07 10:22:59 +00:00
Move conditional RTD dependencies to 'docs' extra
This commit is contained in:
16
setup.py
16
setup.py
@ -1,18 +1,10 @@
|
||||
from setuptools import setup, find_packages
|
||||
import re, os
|
||||
|
||||
on_rtd = os.getenv('READTHEDOCS') == 'True'
|
||||
import re
|
||||
|
||||
requirements = []
|
||||
with open('requirements.txt') as f:
|
||||
requirements = f.read().splitlines()
|
||||
|
||||
if on_rtd:
|
||||
requirements.append('sphinx==1.7.4')
|
||||
requirements.append('sphinxcontrib-napoleon')
|
||||
requirements.append('sphinxcontrib-asyncio')
|
||||
requirements.append('sphinxcontrib-websupport')
|
||||
|
||||
version = ''
|
||||
with open('discord/__init__.py') as f:
|
||||
version = re.search(r'^__version__\s*=\s*[\'"]([^\'"]*)[\'"]', f.read(), re.MULTILINE).group(1)
|
||||
@ -43,7 +35,11 @@ with open('README.rst') as f:
|
||||
|
||||
extras_require = {
|
||||
'voice': ['PyNaCl==1.1.2'],
|
||||
'docs': ['sphinxcontrib-asyncio']
|
||||
'docs': [
|
||||
'sphinx==1.7.4',
|
||||
'sphinxcontrib-asyncio',
|
||||
'sphinxcontrib-websupport',
|
||||
]
|
||||
}
|
||||
|
||||
setup(name='discord.py',
|
||||
|
Reference in New Issue
Block a user