diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index 6b3f00660..bbbfaf9a8 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -89,6 +89,7 @@ Listed in alphabetical order. Delio Castillo `@jangeador`_ @jangeador Denis Orehovsky `@apirobot`_ Dónal Adams `@epileptic-fish`_ + Diane Chen `@purplediane`_ @purplediane88 Dong Huynh `@trungdong`_ Emanuel Calso `@bloodpet`_ @bloodpet Eraldo Energy `@eraldo`_ @@ -99,11 +100,13 @@ Listed in alphabetical order. Garry Polley `@garrypolley`_ Hamish Durkin `@durkode`_ Harry Percival `@hjwp`_ + Hendrik Schneider `@hendrikschneider`_ Henrique G. G. Pereira `@ikkebr`_ Ian Lee `@IanLee1521`_ Jan Van Bruggen `@jvanbrug`_ Jens Nilsson `@phiberjenz`_ Jimmy Gitonga `@afrowave`_ @afrowave + John Cass `@jcass77`_ @cass_john Julien Almarcha `@sladinji`_ Julio Castillo `@juliocc`_ Kaido Kert `@kaidokert`_ @@ -122,6 +125,7 @@ Listed in alphabetical order. Malik Sulaimanov `@flyudvik`_ @flyudvik Martin Blech Martin Saizar `@msaizar`_ + Mateusz Ostaszewski `@mostaszewski`_ Mathijs Hoogland `@MathijsHoogland`_ Matt Braymer-Hayes `@mattayes`_ @mattayes Matt Linares @@ -162,7 +166,7 @@ Listed in alphabetical order. Will Farley `@goldhand`_ @g01dhand William Archinal `@archinal`_ Yaroslav Halchenko - Denis Bobrov `@delneg`_ + Denis Bobrov `@delneg`_ ========================== ============================ ============== .. _@a7p: https://github.com/a7p @@ -209,6 +213,7 @@ Listed in alphabetical order. .. _@goldhand: https://github.com/goldhand .. _@hackebrot: https://github.com/hackebrot .. _@hairychris: https://github.com/hairychris +.. _@hendrikschneider https://github.com/hendrikschneider .. _@hjwp: https://github.com/hjwp .. _@IanLee1521: https://github.com/IanLee1521 .. _@ikkebr: https://github.com/ikkebr @@ -226,6 +231,7 @@ Listed in alphabetical order. .. _@MathijsHoogland: https://github.com/MathijsHoogland .. _@mattayes: https://github.com/mattayes .. _@menzenski: https://github.com/menzenski +.. _@mostaszewski: https://github.com/mostaszewski .. _@mfwarren: https://github.com/mfwarren .. _@mimischi: https://github.com/mimischi .. _@mjsisley: https://github.com/mjsisley @@ -267,6 +273,7 @@ Listed in alphabetical order. .. _@afrowave: https://github.com/afrowave .. _@pchiquet: https://github.com/pchiquet .. _@delneg: https://github.com/delneg +.. _@purplediane: https://github.com/purplediane Special Thanks ~~~~~~~~~~~~~~ diff --git a/README.rst b/README.rst index a69712d07..b5a3e7c0e 100644 --- a/README.rst +++ b/README.rst @@ -41,7 +41,7 @@ Features * For Django 2.0 * Works with Python 3.6 * Renders Django projects with 100% starting test coverage -* Twitter Bootstrap_ v4.0.0 (`maintained Foundation fork`_ also available) +* Twitter Bootstrap_ v4.1.1 (`maintained Foundation fork`_ also available) * 12-Factor_ based settings via django-environ_ * Secure by default. We believe in SSL. * Optimized development and production settings diff --git a/docs/project-generation-options.rst b/docs/project-generation-options.rst index 60453b870..a54837979 100644 --- a/docs/project-generation-options.rst +++ b/docs/project-generation-options.rst @@ -93,7 +93,8 @@ use_travisci: keep_local_envs_in_vcs: Indicates whether the project's ``.envs/.local/`` should be kept in VCS (comes in handy when working in teams where local environment reproducibility - is strongly encouraged). + is strongly encouraged). + Note: .env(s) are only utilized when Docker Compose and/or Heroku support is enabled. debug: Indicates whether the project should be configured for debugging. diff --git a/requirements.txt b/requirements.txt index 77770fa9e..2d40d6c9f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -8,6 +8,6 @@ flake8==3.5.0 # Testing # ------------------------------------------------------------------------------ -tox==3.0.0 -pytest==3.6.2 +tox==3.2.1 +pytest==3.7.2 pytest-cookies==0.3.0 diff --git a/tests/test_docker.sh b/tests/test_docker.sh index bebac1488..78c5717a6 100755 --- a/tests/test_docker.sh +++ b/tests/test_docker.sh @@ -15,7 +15,7 @@ cookiecutter ../../ --no-input --overwrite-if-exists use_docker=y cd my_awesome_project # run the project's tests -docker-compose -f local.yml run django python manage.py test +docker-compose -f local.yml run django python manage.py pytest # return non-zero status code if there are migrations that have not been created docker-compose -f local.yml run django python manage.py makemigrations --dry-run --check || { echo "ERROR: there were changes in the models, but migration listed above have not been created and are not saved in version control"; exit 1; } diff --git a/{{cookiecutter.project_slug}}/README.rst b/{{cookiecutter.project_slug}}/README.rst index 2f40710e2..80923cd88 100644 --- a/{{cookiecutter.project_slug}}/README.rst +++ b/{{cookiecutter.project_slug}}/README.rst @@ -46,7 +46,7 @@ Test coverage To run the tests, check your test coverage, and generate an HTML coverage report:: - $ coverage run manage.py test + $ coverage run -m pytest $ coverage html $ open htmlcov/index.html @@ -55,7 +55,7 @@ Running tests with py.test :: - $ py.test + $ pytest Live reloading and Sass CSS compilation ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -147,7 +147,7 @@ Custom Bootstrap Compilation ^^^^^^ The generated CSS is set up with automatic Bootstrap recompilation with variables of your choice. -Bootstrap v4 is installed using npm and customised by tweaking your variables in ``static/sass/custom_bootstrap_vars``. +Bootstrap v4.1.1 is installed using npm and customised by tweaking your variables in ``static/sass/custom_bootstrap_vars``. You can find a list of available variables `in the bootstrap source`_, or get explanations on them in the `Bootstrap docs`_. @@ -156,6 +156,6 @@ Bootstrap's javascript as well as its dependencies is concatenated into a single {% endif %} .. _in the bootstrap source: https://github.com/twbs/bootstrap/blob/v4-dev/scss/_variables.scss -.. _Bootstrap docs: https://getbootstrap.com/docs/4.0/getting-started/theming/ +.. _Bootstrap docs: https://getbootstrap.com/docs/4.1/getting-started/theming/ {% endif %} diff --git a/{{cookiecutter.project_slug}}/package.json b/{{cookiecutter.project_slug}}/package.json index f32c41a26..03a4e6a28 100644 --- a/{{cookiecutter.project_slug}}/package.json +++ b/{{cookiecutter.project_slug}}/package.json @@ -5,7 +5,7 @@ "devDependencies": { {% if cookiecutter.js_task_runner == 'Gulp' %} {% if cookiecutter.custom_bootstrap_compilation == 'y' %} - "bootstrap": "^4.0.0", + "bootstrap": "4.1.1", {% endif %} "browser-sync": "^2.14.0", "del": "^2.2.2", @@ -23,8 +23,8 @@ "gulp-uglify": "^3.0.0", "gulp-util": "^3.0.7", {% if cookiecutter.custom_bootstrap_compilation == 'y' %} - "jquery": "^3.2.1-slim", - "popper.js": "^1.12.3", + "jquery": "3.3.1-slim", + "popper.js": "1.14.3", {% endif %} "run-sequence": "^2.1.1" {% endif %} diff --git a/{{cookiecutter.project_slug}}/requirements/base.txt b/{{cookiecutter.project_slug}}/requirements/base.txt index 74a417e2d..846e8c18b 100644 --- a/{{cookiecutter.project_slug}}/requirements/base.txt +++ b/{{cookiecutter.project_slug}}/requirements/base.txt @@ -1,16 +1,16 @@ pytz==2018.5 # https://github.com/stub42/pytz python-slugify==1.2.5 # https://github.com/un33k/python-slugify -Pillow==5.1.0 # https://github.com/python-pillow/Pillow +Pillow==5.2.0 # https://github.com/python-pillow/Pillow {%- if cookiecutter.use_compressor == "y" %} rcssmin==1.0.6{% if cookiecutter.windows == 'y' %} --install-option="--without-c-extensions"{% endif %} # https://github.com/ndparker/rcssmin {%- endif %} -argon2-cffi==18.1.0 # https://github.com/hynek/argon2_cffi +argon2-cffi==18.2.0 # https://github.com/hynek/argon2_cffi {%- if cookiecutter.use_whitenoise == 'y' %} -whitenoise==3.3.1 # https://github.com/evansd/whitenoise +whitenoise==4.0 # https://github.com/evansd/whitenoise {%- endif %} redis>=2.10.5 # https://github.com/antirez/redis {%- if cookiecutter.use_celery == "y" %} -celery==4.2.0 # pyup: <5.0 # https://github.com/celery/celery +celery==4.2.1 # pyup: <5.0 # https://github.com/celery/celery {%- if cookiecutter.use_docker == 'y' %} flower==0.9.2 # https://github.com/mher/flower {%- endif %} @@ -18,7 +18,7 @@ flower==0.9.2 # https://github.com/mher/flower # Django # ------------------------------------------------------------------------------ -django==2.0.6 # pyup: < 2.1 # https://www.djangoproject.com/ +django==2.0.8 # pyup: < 2.1 # https://www.djangoproject.com/ django-environ==0.4.5 # https://github.com/joke2k/django-environ django-model-utils==3.1.2 # https://github.com/jazzband/django-model-utils django-allauth==0.36.0 # https://github.com/pennersr/django-allauth diff --git a/{{cookiecutter.project_slug}}/requirements/local.txt b/{{cookiecutter.project_slug}}/requirements/local.txt index b8a7609c2..3ed509c96 100644 --- a/{{cookiecutter.project_slug}}/requirements/local.txt +++ b/{{cookiecutter.project_slug}}/requirements/local.txt @@ -2,7 +2,7 @@ Werkzeug==0.14.1 # https://github.com/pallets/werkzeug ipdb==0.11 # https://github.com/gotcha/ipdb -Sphinx==1.7.5 # https://github.com/sphinx-doc/sphinx +Sphinx==1.7.6 # https://github.com/sphinx-doc/sphinx {%- if cookiecutter.use_docker == 'y' %} psycopg2==2.7.4 --no-binary psycopg2 # https://github.com/psycopg/psycopg2 {%- else %} @@ -11,8 +11,8 @@ psycopg2-binary==2.7.5 # https://github.com/psycopg/psycopg2 # Testing # ------------------------------------------------------------------------------ -mypy==0.610 # https://github.com/python/mypy -pytest==3.6.2 # https://github.com/pytest-dev/pytest +mypy==0.620 # https://github.com/python/mypy +pytest==3.7.2 # https://github.com/pytest-dev/pytest pytest-sugar==0.9.1 # https://github.com/Frozenball/pytest-sugar # Code quality @@ -25,6 +25,6 @@ coverage==4.5.1 # https://github.com/nedbat/coveragepy factory-boy==2.11.1 # https://github.com/FactoryBoy/factory_boy django-debug-toolbar==1.9.1 # https://github.com/jazzband/django-debug-toolbar -django-extensions==2.0.7 # https://github.com/django-extensions/django-extensions +django-extensions==2.1.0 # https://github.com/django-extensions/django-extensions django-coverage-plugin==1.5.0 # https://github.com/nedbat/django_coverage_plugin -pytest-django==3.3.2 # https://github.com/pytest-dev/pytest-django +pytest-django==3.4.1 # https://github.com/pytest-dev/pytest-django diff --git a/{{cookiecutter.project_slug}}/runtime.txt b/{{cookiecutter.project_slug}}/runtime.txt index 486fcce12..1935e9778 100644 --- a/{{cookiecutter.project_slug}}/runtime.txt +++ b/{{cookiecutter.project_slug}}/runtime.txt @@ -1 +1 @@ -python-3.6.5 +python-3.6.6 diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/static/js/project.js b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/static/js/project.js index 91ab9e2da..d26d23b9b 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/static/js/project.js +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/static/js/project.js @@ -1,21 +1 @@ /* Project specific Javascript goes here. */ - -/* -Formatting hack to get around crispy-forms unfortunate hardcoding -in helpers.FormHelper: - - if template_pack == 'bootstrap4': - grid_colum_matcher = re.compile('\w*col-(xs|sm|md|lg|xl)-\d+\w*') - using_grid_layout = (grid_colum_matcher.match(self.label_class) or - grid_colum_matcher.match(self.field_class)) - if using_grid_layout: - items['using_grid_layout'] = True - -Issues with the above approach: - -1. Fragile: Assumes Bootstrap 4's API doesn't change (it does) -2. Unforgiving: Doesn't allow for any variation in template design -3. Really Unforgiving: No way to override this behavior -4. Undocumented: No mention in the documentation, or it's too hard for me to find -*/ -$('.form-group').removeClass('row'); diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html index 2cb705663..6865c929d 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html @@ -17,8 +17,8 @@ {% block css %} {% endraw %}{% if cookiecutter.custom_bootstrap_compilation == "n" %}{% raw %} - - + + {% endraw %}{% endif %}{% raw %} @@ -102,10 +102,10 @@ {% endraw %}{% if cookiecutter.use_compressor == "y" %}{% raw %}{% endcompress %}{% endraw %}{% endif %}{% raw %} {% endraw %}{% else %}{% raw %} - - - - + + + + {% endraw %}{% endif %}{% raw %}