Skip to content

Commit 63b1834

Browse files
committed
Split requirements files up following DRF example
Fixes #712 Fixes #635 This way not all dependency need to be installed for the different testing steps.
1 parent 1753fe9 commit 63b1834

12 files changed

+59
-29
lines changed

.pyup.yml

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
search: False
22
requirements:
3-
- requirements-development.txt:
3+
- requirements/requirements-codestyle.txt:
4+
update: all
5+
pin: True
6+
- requirements/requirements-documentation.txt:
7+
update: all
8+
pin: True
9+
- requirements/requirements-optionals.txt:
10+
update: all
11+
pin: True
12+
- requirements/requirements-packaging.txt:
13+
update: all
14+
pin: True
15+
- requirements/requirements-testing.txt:
416
update: all
517
pin: True

.travis.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ matrix:
1616
include:
1717
- python: 3.6
1818
env: TOXENV=flake8
19+
- python: 3.6
20+
env: TOXENV=docs
1921

2022
- python: 3.5
2123
env: TOXENV=py35-django111-drf310

README.rst

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,7 @@ installed and activated:
126126

127127
$ git clone https://github.com/django-json-api/django-rest-framework-json-api.git
128128
$ cd django-rest-framework-json-api
129-
$ pip install -r example/requirements.txt
130-
$ pip install -e .
129+
$ pip install -U -e . -r requirements.txt
131130
$ django-admin migrate --settings=example.settings
132131
$ django-admin loaddata drf_example --settings=example.settings
133132
$ django-admin runserver --settings=example.settings
@@ -143,7 +142,7 @@ installed and activated:
143142

144143
::
145144

146-
$ pip install -Ur requirements-development.txt
145+
$ pip install -Ur requirements.txt
147146
$ flake8
148147
$ pytest
149148

docs/getting-started.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,7 @@ From Source
7575
cd django-rest-framework-json-api
7676
python3 -m venv env
7777
source env/bin/activate
78-
pip install -r example/requirements.txt
79-
pip install -e .
78+
pip install -U -e . r requirements.txt
8079
django-admin migrate --settings=example.settings
8180
django-admin loaddata drf_example --settings=example.settings
8281
django-admin runserver --settings=example.settings

requirements-development.txt

Lines changed: 0 additions & 16 deletions
This file was deleted.

requirements.txt

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,13 @@
1-
1+
# The base set of requirements for Django REST framework JSON API is actually
2+
# fairly small, but for the purposes of development and testing
3+
# there are a number of packages that are useful to install.
4+
5+
# Laying these out as separate requirements files, allows us to
6+
# only included the relevant sets when running tox, and ensures
7+
# we are only ever declaring our dependencies in one place.
8+
9+
-r requirements/requirements-optionals.txt
10+
-r requirements/requirements-testing.txt
11+
-r requirements/requirements-documentation.txt
12+
-r requirements/requirements-codestyle.txt
13+
-r requirements/requirements-packaging.txt
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
flake8==3.7.7
2+
flake8-isort==2.7.0
3+
isort==4.3.21
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
recommonmark==0.6.0
2+
Sphinx==2.2.0
3+
sphinx_rtd_theme==0.4.3
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
django-filter==2.2.0
2+
django-polymorphic==2.1.2
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
twine==2.0.0

0 commit comments

Comments
 (0)