Browse Source

Merge pull request #1089 from rafalp/move-requirements-to-pip-tools

Use pip-tools to manage requirements.txt
Rafał Pitoń 6 years ago
parent
commit
7372adf6d3
3 changed files with 62 additions and 25 deletions
  1. 18 0
      requirements.in
  2. 39 18
      requirements.txt
  3. 5 7
      setup.py

+ 18 - 0
requirements.in

@@ -0,0 +1,18 @@
+beautifulsoup4<4.7
+bleach<2.2
+django<2
+djangorestframework<3.7
+django-debug-toolbar<1.9
+django-crispy-forms<1.7
+django-htmlmin<0.11
+django-mptt<0.9
+Faker<0.9
+html5lib==0.999999999
+markdown<2.7
+misago-social-auth-app-django
+path.py<10.4
+pillow<4.2
+psycopg2-binary<2.8
+pytz
+requests<3
+unidecode<1

+ 39 - 18
requirements.txt

@@ -1,19 +1,40 @@
-django~=1.11.1
-djangorestframework~=3.6.3
-beautifulsoup4~=4.6.0
-bleach~=2.0.0
-django-debug-toolbar~=1.8
-django-crispy-forms~=1.6.1
-django-htmlmin~=0.10.0
-django-mptt~=0.8.7
-Faker~=0.8.11
+#
+# This file is autogenerated by pip-compile
+# To update, run:
+#
+#    pip-compile --output-file requirements.txt requirements.in
+#
+beautifulsoup4==4.6.3
+bleach==2.1.4
+certifi==2018.8.24        # via requests
+chardet==3.0.4            # via requests
+django-crispy-forms==1.6.1
+django-debug-toolbar==1.8
+django-htmlmin==0.10.0
+django-mptt==0.8.7
+django==1.11.15
+djangorestframework==3.6.4
+faker==0.8.18
 html5lib==0.999999999
 html5lib==0.999999999
-markdown~=2.6.8
-path.py~=10.3.1
-pillow~=4.1.1
-psycopg2-binary~=2.7.1
-pytz
-pyyaml~=3.13
-requests<3
-misago-social-auth-app-django~=2.1.0
-unidecode~=0.4.20
+idna==2.7                 # via requests
+ipaddress==1.0.22         # via faker
+markdown==2.6.11
+misago-social-auth-app-django==2.1.0
+oauthlib==2.1.0           # via requests-oauthlib, social-auth-core
+olefile==0.45.1           # via pillow
+path.py==10.3.1
+pillow==4.1.1
+psycopg2-binary==2.7.5
+pyjwt==1.6.4              # via social-auth-core
+python-dateutil==2.7.3    # via faker
+python-openid==2.2.5      # via social-auth-core
+pytz==2018.5
+requests-oauthlib==1.0.0  # via social-auth-core
+requests==2.19.1
+six==1.11.0               # via bleach, faker, html5lib, misago-social-auth-app-django, python-dateutil, social-auth-core
+social-auth-core==1.7.0   # via misago-social-auth-app-django
+sqlparse==0.2.4           # via django-debug-toolbar
+text-unidecode==1.2       # via faker
+unidecode==0.4.21
+urllib3==1.23             # via requests
+webencodings==0.5.1       # via html5lib

+ 5 - 7
setup.py

@@ -8,21 +8,19 @@ from misago import __version__ as version
 
 
 SETUP_DIR = os.path.dirname(__file__)
 SETUP_DIR = os.path.dirname(__file__)
 
 
-README = open(os.path.join(SETUP_DIR, 'README.rst'), 'rb').read().decode('utf-8')
+with open(os.path.join(SETUP_DIR, 'README.rst'), 'rb') as f:
+    README = f.read().decode('utf-8')
 
 
 with open(os.path.join(SETUP_DIR, 'requirements.txt'), "r") as f:
 with open(os.path.join(SETUP_DIR, 'requirements.txt'), "r") as f:
-    REQUIREMENTS = [x.strip() for x in f.readlines()]
-
-
-# allow setup.py to be run from any path
-os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
-
+    REQUIREMENTS = f.read()
 
 
 EXCLUDE_FROM_PACKAGES = [
 EXCLUDE_FROM_PACKAGES = [
     'misago.project_template',
     'misago.project_template',
     'misago.bin'
     'misago.bin'
 ]
 ]
 
 
+# allow setup.py to be run from any path
+os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
 
 
 setup(
 setup(
     name='Misago',
     name='Misago',