From a023ed7a359c7235cee48d18e6a0f206a8c43853 Mon Sep 17 00:00:00 2001 From: Krzysztof Szumny Date: Sun, 10 Apr 2016 23:18:38 +0200 Subject: [PATCH 01/22] mailhog-as-docker-container --- {{cookiecutter.repo_name}}/config/settings/local.py | 9 ++++++--- {{cookiecutter.repo_name}}/dev.yml | 7 +++++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/{{cookiecutter.repo_name}}/config/settings/local.py b/{{cookiecutter.repo_name}}/config/settings/local.py index b8408c0af..7af3f46c6 100644 --- a/{{cookiecutter.repo_name}}/config/settings/local.py +++ b/{{cookiecutter.repo_name}}/config/settings/local.py @@ -23,12 +23,15 @@ SECRET_KEY = env('DJANGO_SECRET_KEY', default='CHANGEME!!!') # Mail settings # ------------------------------------------------------------------------------ -EMAIL_HOST = 'localhost' + EMAIL_PORT = 1025 -{%if cookiecutter.use_mailhog == 'n' -%} +{% if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'y' %} +EMAIL_HOST = 'mailhog' +{% else %} +EMAIL_HOST = 'localhost' EMAIL_BACKEND = env('DJANGO_EMAIL_BACKEND', default='django.core.mail.backends.console.EmailBackend') -{%- endif %} +{% endif %} # CACHING # ------------------------------------------------------------------------------ diff --git a/{{cookiecutter.repo_name}}/dev.yml b/{{cookiecutter.repo_name}}/dev.yml index 95353a959..490ffc863 100644 --- a/{{cookiecutter.repo_name}}/dev.yml +++ b/{{cookiecutter.repo_name}}/dev.yml @@ -42,3 +42,10 @@ services: links: - postgres {% endif %} + +{% if cookiecutter.use_mailhog == 'y' %} + mailhog: + image: mailhog/mailhog + ports: + - "8025:8025" +{% endif %} From 7c4135fb45ded2716ce9af7e085402683b6a4773 Mon Sep 17 00:00:00 2001 From: Krzysztof Szumny Date: Sun, 10 Apr 2016 23:51:34 +0200 Subject: [PATCH 02/22] grunt and documentation cleanning --- docs/developing-locally.rst | 8 +++----- {{cookiecutter.repo_name}}/.gitignore | 3 --- {{cookiecutter.repo_name}}/Gruntfile.js | 6 ------ {{cookiecutter.repo_name}}/README.rst | 14 ++++---------- 4 files changed, 7 insertions(+), 24 deletions(-) diff --git a/docs/developing-locally.rst b/docs/developing-locally.rst index b45883d1e..b31990c5c 100644 --- a/docs/developing-locally.rst +++ b/docs/developing-locally.rst @@ -42,14 +42,12 @@ django-allauth sends an email to verify users (and superusers) after signup and .. _configure your email backend: http://docs.djangoproject.com/en/1.9/topics/email/#smtp-backend -In development you can (optionally) use MailHog_ for email testing. MailHog is built with Go so there are no dependencies. To use MailHog:: +In development you can (optionally) use MailHog_ for email testing. MailHog is added as docker-container. To use MailHog:: -1. `Download the latest release`_ for your operating system -2. Rename the executable to ``mailhog`` and copy it to the root of your project directory -3. Make sure it is executable (e.g. ``chmod +x mailhog``) +1. Make sure, that ``mailhog`` docker container is up and running +2. Open your browser and go to ``http://127.0.0.1:8025`` .. _Mailhog: https://github.com/mailhog/MailHog/ -.. _Download the latest release: https://github.com/mailhog/MailHog/releases Alternatively simply output emails to the console via: ``EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'`` diff --git a/{{cookiecutter.repo_name}}/.gitignore b/{{cookiecutter.repo_name}}/.gitignore index b4f3f5b9b..8e9a45efc 100644 --- a/{{cookiecutter.repo_name}}/.gitignore +++ b/{{cookiecutter.repo_name}}/.gitignore @@ -70,6 +70,3 @@ node_modules/ # Hitch directory tests/.hitch - -# MailHog binary -mailhog diff --git a/{{cookiecutter.repo_name}}/Gruntfile.js b/{{cookiecutter.repo_name}}/Gruntfile.js index 1eaade285..cf3f25c70 100644 --- a/{{cookiecutter.repo_name}}/Gruntfile.js +++ b/{{cookiecutter.repo_name}}/Gruntfile.js @@ -112,16 +112,10 @@ module.exports = function (grunt) { runDjango: { cmd: 'python <%= paths.manageScript %> runserver' }, - {% if cookiecutter.use_mailhog == "y" -%}runMailHog: { - cmd: './mailhog' - },{%- endif %} } }); grunt.registerTask('serve', [ - {% if cookiecutter.use_mailhog == "y" -%} - 'bgShell:runMailHog', - {%- endif %} 'bgShell:runDjango', 'watch' ]); diff --git a/{{cookiecutter.repo_name}}/README.rst b/{{cookiecutter.repo_name}}/README.rst index a23d0dbf9..569577193 100644 --- a/{{cookiecutter.repo_name}}/README.rst +++ b/{{cookiecutter.repo_name}}/README.rst @@ -78,20 +78,14 @@ Please note: For Celery's import magic to work, it is important *where* the cele Email Server ^^^^^^^^^^^^ -In development, it is often nice to be able to see emails that are being sent from your application. If you choose to use `MailHog`_ when generating the project a local SMTP server with a web interface will be available. +In development, it is often nice to be able to see emails that are being sent from your application. For that reason local SMTP server `MailHog`_ with a web interface is available as docker container. .. _mailhog: https://github.com/mailhog/MailHog -To start the service, make sure you have nodejs installed, and then type the following:: +Container mailhog will start automatically when you will run all docker containers. +Please check `cookiecutter-django Docker documentation`_ for more details how to start all containers. - $ npm install - $ grunt serve - -(After the first run you only need to type ``grunt serve``) This will start an email server that listens on ``127.0.0.1:1025`` in addition to starting your Django project and a watch task for live reload. - -To view messages that are sent by your application, open your browser and go to ``http://127.0.0.1:8025`` - -The email server will exit when you exit the Grunt task on the CLI with Ctrl+C. +With MailHog running, to view messages that are sent by your application, open your browser and go to ``http://127.0.0.1:8025`` {% endif %} From 2ea29d263dcd6fabf07b0e196619ce09f971c0a1 Mon Sep 17 00:00:00 2001 From: Krzysztof Szumny Date: Mon, 11 Apr 2016 00:33:14 +0200 Subject: [PATCH 03/22] Fix for tests --- {{cookiecutter.repo_name}}/config/settings/local.py | 2 +- {{cookiecutter.repo_name}}/dev.yml | 4 ++++ {{cookiecutter.repo_name}}/tests/all.settings | 1 + 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/{{cookiecutter.repo_name}}/config/settings/local.py b/{{cookiecutter.repo_name}}/config/settings/local.py index 7af3f46c6..b3227a2b6 100644 --- a/{{cookiecutter.repo_name}}/config/settings/local.py +++ b/{{cookiecutter.repo_name}}/config/settings/local.py @@ -26,7 +26,7 @@ SECRET_KEY = env('DJANGO_SECRET_KEY', default='CHANGEME!!!') EMAIL_PORT = 1025 {% if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'y' %} -EMAIL_HOST = 'mailhog' +EMAIL_HOST = env("EMAIL_HOST", default='mailhog') {% else %} EMAIL_HOST = 'localhost' EMAIL_BACKEND = env('DJANGO_EMAIL_BACKEND', diff --git a/{{cookiecutter.repo_name}}/dev.yml b/{{cookiecutter.repo_name}}/dev.yml index 490ffc863..c4596d401 100644 --- a/{{cookiecutter.repo_name}}/dev.yml +++ b/{{cookiecutter.repo_name}}/dev.yml @@ -28,6 +28,10 @@ services: - "8000:8000" links: - postgres +{% if cookiecutter.use_mailhog == 'y' %} + - mailhog +{% endif %} + {% if cookiecutter.use_pycharm == 'y' %} pycharm: build: diff --git a/{{cookiecutter.repo_name}}/tests/all.settings b/{{cookiecutter.repo_name}}/tests/all.settings index 0c3965603..4907ec81b 100644 --- a/{{cookiecutter.repo_name}}/tests/all.settings +++ b/{{cookiecutter.repo_name}}/tests/all.settings @@ -11,6 +11,7 @@ environment_variables: SECRET_KEY: cj5^uos4tfCdfghjkf5hq$9$(@-79^e9&x$3vyf#igvsfm4d=+ CELERY_BROKER_URL: redis://localhost:16379 DJANGO_EMAIL_BACKEND: django.core.mail.backends.smtp.EmailBackend + EMAIL_HOST: localhost window_size: width: 1024 height: 600 From 8a682818b33efab41fb8bc460c01d3a4c8972640 Mon Sep 17 00:00:00 2001 From: Krzysztof Szumny Date: Mon, 18 Apr 2016 23:10:49 +0200 Subject: [PATCH 04/22] Additional conditions with use_docker --- docs/developing-locally.rst | 11 ++++++++++- {{cookiecutter.repo_name}}/.gitignore | 4 ++++ {{cookiecutter.repo_name}}/Gruntfile.js | 6 ++++++ {{cookiecutter.repo_name}}/README.rst | 17 ++++++++++++++++- 4 files changed, 36 insertions(+), 2 deletions(-) diff --git a/docs/developing-locally.rst b/docs/developing-locally.rst index b31990c5c..14e72046c 100644 --- a/docs/developing-locally.rst +++ b/docs/developing-locally.rst @@ -41,14 +41,23 @@ You can now run the usual Django ``migrate`` and ``runserver`` commands:: django-allauth sends an email to verify users (and superusers) after signup and login (if they are still not verified). To send email you need to `configure your email backend`_ .. _configure your email backend: http://docs.djangoproject.com/en/1.9/topics/email/#smtp-backend - +{% if cookiecutter.use_docker == 'y' %} In development you can (optionally) use MailHog_ for email testing. MailHog is added as docker-container. To use MailHog:: 1. Make sure, that ``mailhog`` docker container is up and running 2. Open your browser and go to ``http://127.0.0.1:8025`` .. _Mailhog: https://github.com/mailhog/MailHog/ +{% else %} +In development you can (optionally) use MailHog_ for email testing. MailHog is built with Go so there are no dependencies. To use MailHog:: +1. `Download the latest release`_ for your operating system +2. Rename the executable to ``mailhog`` and copy it to the root of your project directory +3. Make sure it is executable (e.g. ``chmod +x mailhog``) + +.. _Mailhog: https://github.com/mailhog/MailHog/ +.. _Download the latest release: https://github.com/mailhog/MailHog/releases +{% endif %} Alternatively simply output emails to the console via: ``EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'`` In production basic email configuration is setup to send emails with Mailgun_ diff --git a/{{cookiecutter.repo_name}}/.gitignore b/{{cookiecutter.repo_name}}/.gitignore index 8e9a45efc..aebef5994 100644 --- a/{{cookiecutter.repo_name}}/.gitignore +++ b/{{cookiecutter.repo_name}}/.gitignore @@ -70,3 +70,7 @@ node_modules/ # Hitch directory tests/.hitch +{% if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'n'%} +# MailHog binary +mailhog +{% endif %} diff --git a/{{cookiecutter.repo_name}}/Gruntfile.js b/{{cookiecutter.repo_name}}/Gruntfile.js index cf3f25c70..e5fbcceed 100644 --- a/{{cookiecutter.repo_name}}/Gruntfile.js +++ b/{{cookiecutter.repo_name}}/Gruntfile.js @@ -112,10 +112,16 @@ module.exports = function (grunt) { runDjango: { cmd: 'python <%= paths.manageScript %> runserver' }, + {% if cookiecutter.use_mailhog == "y" and cookiecutter.use_docker == 'n' -%}runMailHog: { + cmd: './mailhog' + },{%- endif %} } }); grunt.registerTask('serve', [ + {% if cookiecutter.use_mailhog == "y" and cookiecutter.use_docker == 'n' -%} + 'bgShell:runMailHog', + {%- endif %} 'bgShell:runDjango', 'watch' ]); diff --git a/{{cookiecutter.repo_name}}/README.rst b/{{cookiecutter.repo_name}}/README.rst index 569577193..bfdbff3c4 100644 --- a/{{cookiecutter.repo_name}}/README.rst +++ b/{{cookiecutter.repo_name}}/README.rst @@ -77,7 +77,7 @@ Please note: For Celery's import magic to work, it is important *where* the cele Email Server ^^^^^^^^^^^^ - +{% if cookiecutter.use_docker == 'y' %} In development, it is often nice to be able to see emails that are being sent from your application. For that reason local SMTP server `MailHog`_ with a web interface is available as docker container. .. _mailhog: https://github.com/mailhog/MailHog @@ -86,7 +86,22 @@ Container mailhog will start automatically when you will run all docker containe Please check `cookiecutter-django Docker documentation`_ for more details how to start all containers. With MailHog running, to view messages that are sent by your application, open your browser and go to ``http://127.0.0.1:8025`` +{% else %} +In development, it is often nice to be able to see emails that are being sent from your application. If you choose to use `MailHog`_ when generating the project a local SMTP server with a web interface will be available. +.. _mailhog: https://github.com/mailhog/MailHog + +To start the service, make sure you have nodejs installed, and then type the following:: + + $ npm install + $ grunt serve + +(After the first run you only need to type ``grunt serve``) This will start an email server that listens on ``127.0.0.1:1025`` in addition to starting your Django project and a watch task for live reload. + +To view messages that are sent by your application, open your browser and go to ``http://127.0.0.1:8025`` + +The email server will exit when you exit the Grunt task on the CLI with Ctrl+C. +{% endif %} {% endif %} {% if cookiecutter.use_sentry == "y" %} From 8cbe97bb9f64d780c1521deac6e106d92ba12e2d Mon Sep 17 00:00:00 2001 From: shireenrao Date: Mon, 9 May 2016 14:33:21 -0400 Subject: [PATCH 05/22] Added a comment on how to use mailhog As somebody new to mailhog, I was a confused on how to use it. I first assumed, it was going to be used by the django app itself. After reading more on the internet I found it needed to be executed outside of the django application. --- docs/developing-locally.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/developing-locally.rst b/docs/developing-locally.rst index 73fac3cbe..1a65ed6ec 100644 --- a/docs/developing-locally.rst +++ b/docs/developing-locally.rst @@ -47,6 +47,8 @@ In development you can (optionally) use MailHog_ for email testing. MailHog is b 1. `Download the latest release`_ for your operating system 2. Rename the executable to ``mailhog`` and copy it to the root of your project directory 3. Make sure it is executable (e.g. ``chmod +x mailhog``) +4. Execute mailhog from the root of your project in a new terminal window (e.g. ``./mailhog``) +5. All emails generated from your django app can be seen on http://127.0.0.1:8025/ .. _Mailhog: https://github.com/mailhog/MailHog/ .. _Download the latest release: https://github.com/mailhog/MailHog/releases From 8c3996439a86d5752beed06ed5c2de888ec27b76 Mon Sep 17 00:00:00 2001 From: "Fabio C. Barrioneuvo da Luz" Date: Mon, 9 May 2016 17:01:51 -0300 Subject: [PATCH 06/22] update changelog --- CHANGELOG.md | 19 +++++++++++++++++++ CONTRIBUTORS.rst | 6 ++++++ 2 files changed, 25 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 383521506..6a5d402a9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,25 @@ All enhancements and patches to Cookiecutter Django will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [2016-05-09] +### Changed +- Improved mailhog usage documentation on `developing-locally.rst` (@shireenrao) + +## [2016-05-08] +### Changed +- Updated whitenoise configuration to match changes in version 3.0 (@trungdong) + +## [2016-05-07] +### Added +- Added Ubuntu 16.04 dependencies on a new dependency file `requirements.apt.xenial` (@raonyguimaraes) + +### Changed +- Small improvements in ``install_os_dependencies.sh`` support new dependency file (@raonyguimaraes) + +## [2016-05-06] +### Changed +- Update version of pyflakes (@pydanny) + ## [2016-05-03] ### Changed - Update version of Django, django-extensions, django-mailgun (@luzfcb) diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index 6b5dcda78..a1cbdfc19 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -67,6 +67,7 @@ Listed in alphabetical order. David Díaz `@ddiazpinto`_ @DavidDiazPinto Davur Clementsen `@dsclementsen`_ @davur Dónal Adams `@epileptic-fish`_ + Dong Huynh `@trungdong`_ Eraldo Energy `@eraldo`_ Eyad Al Sibai `@eyadsibai`_ Felipe Arruda `@arruda`_ @@ -95,11 +96,13 @@ Listed in alphabetical order. mozillazg `@mozillazg`_ Pablo `@oubiga`_ Raphael Pierzina `@hackebrot`_ + Raony Guimarães Corrêa `@raonyguimaraes`_ Roman Afanaskin `@siauPatrick`_ Roman Osipenko `@romanosipenko`_ Russell Davies stepmr `@stepmr`_ Sławek Ehlert `@slafs`_ + Srinivas Nyayapati `@shireenrao`_ Taylor Baldwin Théo Segonds `@show0k`_ Tom Atkins `@knitatoms`_ @@ -154,11 +157,14 @@ Listed in alphabetical order. .. _@originell: https://github.com/originell .. _@oubiga: https://github.com/oubiga .. _@romanosipenko: https://github.com/romanosipenko +.. _@raonyguimaraes: https://github.com/raonyguimaraes .. _@show0k: https://github.com/show0k .. _@siauPatrick: https://github.com/siauPatrick +.. _@shireenrao: https://github.com/shireenrao .. _@slafs: https://github.com/slafs .. _@stepmr: https://github.com/stepmr .. _@Travistock: https://github.com/Tavistock +.. _@trungdong: https://github.com/trungdong .. _@yunti: https://github.com/yunti .. _@zcho: https://github.com/zcho .. _@noisy: https://github.com/noisy From 2b878fcf36ee1ce854c67455693650ec1f289168 Mon Sep 17 00:00:00 2001 From: "Fabio C. Barrioneuvo da Luz" Date: Mon, 9 May 2016 17:18:58 -0300 Subject: [PATCH 07/22] replace occurrences of readthedocs.org to readthedocs.io --- CHANGELOG.md | 3 ++- CONTRIBUTING.rst | 2 +- README.rst | 8 ++++---- docs/developing-locally.rst | 2 +- {{cookiecutter.project_slug}}/README.rst | 8 ++++---- {{cookiecutter.project_slug}}/config/settings/common.py | 2 +- .../config/settings/production.py | 4 ++-- .../{{cookiecutter.project_slug}}/contrib/__init__.py | 2 +- .../contrib/sites/__init__.py | 2 +- .../sites/migrations/0002_set_site_domain_and_name.py | 2 +- .../contrib/sites/migrations/__init__.py | 2 +- 11 files changed, 19 insertions(+), 18 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6a5d402a9..0ab64f2d7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). ## [2016-05-09] ### Changed - Improved mailhog usage documentation on `developing-locally.rst` (@shireenrao) +- Replaced all `readthedocs.org` referencies to point to the new domain `readthedocs.io` (@luzfcb) ## [2016-05-08] ### Changed @@ -537,7 +538,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). - Styles that already exist in Bootstrap 4 (or 3) (@audreyr) ### Changed -- Fix issue #296 - change login.html to use [get_providers](https://github.com/pennersr/django-allauth/blob/master/allauth/socialaccount/templatetags/socialaccount.py#L84-L93) templatetag because ``allauth.socialaccount`` context processor now is [deprecated](http://django-allauth.readthedocs.org/en/latest/changelog.html#from-0-21-0) (@luzfcb) +- Fix issue #296 - change login.html to use [get_providers](https://github.com/pennersr/django-allauth/blob/master/allauth/socialaccount/templatetags/socialaccount.py#L84-L93) templatetag because ``allauth.socialaccount`` context processor now is [deprecated](http://django-allauth.readthedocs.io/en/latest/changelog.html#from-0-21-0) (@luzfcb) ## [2015-09-09] ### Added diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst index d05ea0dbd..9acc83287 100644 --- a/CONTRIBUTING.rst +++ b/CONTRIBUTING.rst @@ -49,7 +49,7 @@ To run a particular test with tox for against your current Python version:: $ tox -e py -- -k test_default_configuration .. _`pytest usage docs`: https://pytest.org/latest/usage.html#specifying-tests-selecting-tests -.. _`tox`: https://tox.readthedocs.org/en/latest/ +.. _`tox`: https://tox.readthedocs.io/en/latest/ .. _`pip`: https://pypi.python.org/pypi/pip/ .. _`pytest-cookies`: https://pypi.python.org/pypi/pytest-cookies/ .. _`flake8`: https://pypi.python.org/pypi/flake8/ diff --git a/README.rst b/README.rst index ce174290d..4b4d3af15 100644 --- a/README.rst +++ b/README.rst @@ -58,7 +58,7 @@ Optional Integrations .. _django-avatar: https://github.com/jezdez/django-avatar/ .. _Procfile: https://devcenter.heroku.com/articles/procfile .. _Mailgun: https://mailgun.com/ -.. _Whitenoise: https://whitenoise.readthedocs.org/ +.. _Whitenoise: https://whitenoise.readthedocs.io/ .. _Celery: http://www.celeryproject.org/ .. _MailHog: https://github.com/mailhog/MailHog .. _Sentry: https://getsentry.com @@ -153,9 +153,9 @@ For development, see the following for local development: * `Developing locally`_ * `Developing locally using docker`_ -.. _options: http://cookiecutter-django.readthedocs.org/en/latest/project-generation-options.html -.. _`Developing locally`: http://cookiecutter-django.readthedocs.org/en/latest/developing-locally.html -.. _`Developing locally using docker`: http://cookiecutter-django.readthedocs.org/en/latest/developing-locally-docker.html +.. _options: http://cookiecutter-django.readthedocs.io/en/latest/project-generation-options.html +.. _`Developing locally`: http://cookiecutter-django.readthedocs.io/en/latest/developing-locally.html +.. _`Developing locally using docker`: http://cookiecutter-django.readthedocs.io/en/latest/developing-locally-docker.html Community ----------- diff --git a/docs/developing-locally.rst b/docs/developing-locally.rst index 1a65ed6ec..27460eb00 100644 --- a/docs/developing-locally.rst +++ b/docs/developing-locally.rst @@ -29,7 +29,7 @@ Then, create a PostgreSQL database with the following command, where `[project_s $ export DATABASE_URL="postgres://**:**\ @127.0.0.1:\ **/**" -.. _django-environ: http://django-environ.readthedocs.org +.. _django-environ: http://django-environ.readthedocs.io You can now run the usual Django ``migrate`` and ``runserver`` commands:: diff --git a/{{cookiecutter.project_slug}}/README.rst b/{{cookiecutter.project_slug}}/README.rst index 038d73adc..4717b7b91 100644 --- a/{{cookiecutter.project_slug}}/README.rst +++ b/{{cookiecutter.project_slug}}/README.rst @@ -16,7 +16,7 @@ Settings Moved to settings_. -.. _settings: http://cookiecutter-django.readthedocs.org/en/latest/settings.html +.. _settings: http://cookiecutter-django.readthedocs.io/en/latest/settings.html Basic Commands -------------- @@ -53,7 +53,7 @@ Live reloading and Sass CSS compilation Moved to `Live reloading and SASS compilation`_. -.. _`Live reloading and SASS compilation`: http://cookiecutter-django.readthedocs.org/en/latest/live-reloading-and-sass-compilation.html +.. _`Live reloading and SASS compilation`: http://cookiecutter-django.readthedocs.io/en/latest/live-reloading-and-sass-compilation.html {% if cookiecutter.use_celery == "y" %} @@ -121,7 +121,7 @@ Heroku See detailed `cookiecutter-django Heroku documentation`_. -.. _`cookiecutter-django Heroku documentation`: http://cookiecutter-django.readthedocs.org/en/latest/deployment-on-heroku.html +.. _`cookiecutter-django Heroku documentation`: http://cookiecutter-django.readthedocs.io/en/latest/deployment-on-heroku.html {% endif %} @@ -132,6 +132,6 @@ Docker See detailed `cookiecutter-django Docker documentation`_. -.. _`cookiecutter-django Docker documentation`: http://cookiecutter-django.readthedocs.org/en/latest/deployment-with-docker.html +.. _`cookiecutter-django Docker documentation`: http://cookiecutter-django.readthedocs.io/en/latest/deployment-with-docker.html {% endif %} diff --git a/{{cookiecutter.project_slug}}/config/settings/common.py b/{{cookiecutter.project_slug}}/config/settings/common.py index 276e97e28..292da8826 100644 --- a/{{cookiecutter.project_slug}}/config/settings/common.py +++ b/{{cookiecutter.project_slug}}/config/settings/common.py @@ -163,7 +163,7 @@ TEMPLATES = [ }, ] -# See: http://django-crispy-forms.readthedocs.org/en/latest/install.html#template-packs +# See: http://django-crispy-forms.readthedocs.io/en/latest/install.html#template-packs CRISPY_TEMPLATE_PACK = 'bootstrap3' # STATIC FILE CONFIGURATION diff --git a/{{cookiecutter.project_slug}}/config/settings/production.py b/{{cookiecutter.project_slug}}/config/settings/production.py index 8baeebd89..201b8b875 100644 --- a/{{cookiecutter.project_slug}}/config/settings/production.py +++ b/{{cookiecutter.project_slug}}/config/settings/production.py @@ -46,7 +46,7 @@ SECURITY_MIDDLEWARE = ( ) {% if cookiecutter.use_whitenoise == 'y' -%} # Use Whitenoise to serve static files -# See: https://whitenoise.readthedocs.org/ +# See: https://whitenoise.readthedocs.io/ WHITENOISE_MIDDLEWARE = ( 'whitenoise.middleware.WhiteNoiseMiddleware', ) @@ -98,7 +98,7 @@ INSTALLED_APPS += ('gunicorn', ) # ------------------------------------------------------------------------------ # Uploaded Media Files # ------------------------ -# See: http://django-storages.readthedocs.org/en/latest/index.html +# See: http://django-storages.readthedocs.io/en/latest/index.html INSTALLED_APPS += ( 'storages', ) diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/__init__.py b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/__init__.py index 4985ac95d..776ac1718 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/__init__.py +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/__init__.py @@ -1,6 +1,6 @@ """ To understand why this file is here, please read: -http://cookiecutter-django.readthedocs.org/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django +http://cookiecutter-django.readthedocs.io/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django """ # -*- coding: utf-8 -*- diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/__init__.py b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/__init__.py index 4985ac95d..776ac1718 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/__init__.py +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/__init__.py @@ -1,6 +1,6 @@ """ To understand why this file is here, please read: -http://cookiecutter-django.readthedocs.org/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django +http://cookiecutter-django.readthedocs.io/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django """ # -*- coding: utf-8 -*- diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/0002_set_site_domain_and_name.py b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/0002_set_site_domain_and_name.py index c4e255d8e..e6292f0b0 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/0002_set_site_domain_and_name.py +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/0002_set_site_domain_and_name.py @@ -1,7 +1,7 @@ """ To understand why this file is here, please read: -http://cookiecutter-django.readthedocs.org/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django +http://cookiecutter-django.readthedocs.io/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django """ # -*- coding: utf-8 -*- diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/__init__.py b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/__init__.py index 4985ac95d..776ac1718 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/__init__.py +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/contrib/sites/migrations/__init__.py @@ -1,6 +1,6 @@ """ To understand why this file is here, please read: -http://cookiecutter-django.readthedocs.org/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django +http://cookiecutter-django.readthedocs.io/en/latest/faq.html#why-is-there-a-django-contrib-sites-directory-in-cookiecutter-django """ # -*- coding: utf-8 -*- From d79e09d0e2a707b2f0029091fdb5c47018cf7600 Mon Sep 17 00:00:00 2001 From: "Fabio C. Barrioneuvo da Luz" Date: Mon, 9 May 2016 17:38:14 -0300 Subject: [PATCH 08/22] update version of pyflakes --- CHANGELOG.md | 1 + requirements.txt | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0ab64f2d7..7056d62cb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). ### Changed - Improved mailhog usage documentation on `developing-locally.rst` (@shireenrao) - Replaced all `readthedocs.org` referencies to point to the new domain `readthedocs.io` (@luzfcb) +- Update version of pyflakes (@luzfcb) ## [2016-05-08] ### Changed diff --git a/requirements.txt b/requirements.txt index 58369fe35..444c9fd35 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,6 +6,6 @@ binaryornot==0.4.0 # Testing pytest==2.9.1 pep8==1.7.0 -pyflakes==1.2.1 +pyflakes==1.2.2 tox==2.3.1 pytest-cookies==0.2.0 From 7b24c19ce54d21d678ccd084a4c8747e966ec794 Mon Sep 17 00:00:00 2001 From: Daniel Roy Greenfeld Date: Mon, 9 May 2016 21:12:34 -0700 Subject: [PATCH 09/22] Fix #524 --- LICENSE | 4 ++-- docs/conf.py | 8 ++++---- docs/developing-locally.rst | 2 +- docs/faq.rst | 2 +- hooks/post_gen_project.py | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/LICENSE b/LICENSE index bf45127cf..9a5d2fc08 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2013, Daniel Greenfeld +Copyright (c) 2013-2016, Daniel Greenfeld All rights reserved. Redistribution and use in source and binary forms, with or without modification, @@ -11,7 +11,7 @@ are permitted provided that the following conditions are met: list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -* Neither the name of cookiecutter-django nor the names of its contributors may +* Neither the name of Cookiecutter Django nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. diff --git a/docs/conf.py b/docs/conf.py index f666389a1..2fdeb69e6 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -45,7 +45,7 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = 'cookiecutter-django' +project = 'Cookiecutter Django' copyright = '2013-{}, Daniel Roy Greenfeld'.format(now.year) # The version info for the project you're documenting, acts as replacement for @@ -220,7 +220,7 @@ latex_documents = [ # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). man_pages = [ - ('index', 'cookiecutter-django', 'cookiecutter-django documentation', + ('index', 'Cookiecutter Django', 'Cookiecutter Django documentation', ['Daniel Roy Greenfeld'], 1) ] @@ -234,8 +234,8 @@ man_pages = [ # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - ('index', 'cookiecutter-django', 'cookiecutter-django documentation', - 'Daniel Roy Greenfeld', 'cookiecutter-django', + ('index', 'Cookiecutter Django', 'Cookiecutter Django documentation', + 'Daniel Roy Greenfeld', 'Cookiecutter Django', 'A Cookiecutter template for creating production-ready Django projects quickly.', 'Miscellaneous'), ] diff --git a/docs/developing-locally.rst b/docs/developing-locally.rst index 27460eb00..4963a9cda 100644 --- a/docs/developing-locally.rst +++ b/docs/developing-locally.rst @@ -23,7 +23,7 @@ Then, create a PostgreSQL database with the following command, where `[project_s $ createdb [project_slug] -`cookiecutter-django` uses the excellent `django-environ`_ package with its ``DATABASE_URL`` environment variable to simplify database configuration in your Django settings. Now all you have to do is compose a definition for ``DATABASE_URL``: +`Cookiecutter Django` uses the excellent `django-environ`_ package with its ``DATABASE_URL`` environment variable to simplify database configuration in your Django settings. Now all you have to do is compose a definition for ``DATABASE_URL``: .. parsed-literal:: diff --git a/docs/faq.rst b/docs/faq.rst index 3e6e4a7e5..854e9dddd 100644 --- a/docs/faq.rst +++ b/docs/faq.rst @@ -3,7 +3,7 @@ FAQ .. index:: FAQ, 12-Factor App -Why is there a django.contrib.sites directory in cookiecutter-django? +Why is there a django.contrib.sites directory in Cookiecutter Django? --------------------------------------------------------------------- It is there to add a migration so you don't have to manually change the ``sites.Site`` record from ``example.com`` to whatever your domain is. Instead, your ``{{cookiecutter.domain_name}}`` and {{cookiecutter.project_name}} value is placed by **Cookiecutter** in the domain and name fields respectively. diff --git a/hooks/post_gen_project.py b/hooks/post_gen_project.py index bbc852420..cffb052e8 100644 --- a/hooks/post_gen_project.py +++ b/hooks/post_gen_project.py @@ -39,7 +39,7 @@ def get_random_string( if using_sysrandom: return ''.join(random.choice(allowed_chars) for i in range(length)) print( - "cookiecutter-django couldn't find a secure pseudo-random number generator on your system." + "Cookiecutter Django couldn't find a secure pseudo-random number generator on your system." " Please change change your SECRET_KEY variables in conf/settings/local.py and env.example" " manually." ) From c7c1d0bfa14c7a66facb035cad5d100798d9a0be Mon Sep 17 00:00:00 2001 From: Daniel Roy Greenfeld Date: Wed, 11 May 2016 21:53:30 -0700 Subject: [PATCH 10/22] Remove Raven 404 catch middleware. Fix #367 --- {{cookiecutter.project_slug}}/config/settings/production.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/{{cookiecutter.project_slug}}/config/settings/production.py b/{{cookiecutter.project_slug}}/config/settings/production.py index 201b8b875..cf35861fa 100644 --- a/{{cookiecutter.project_slug}}/config/settings/production.py +++ b/{{cookiecutter.project_slug}}/config/settings/production.py @@ -53,8 +53,9 @@ WHITENOISE_MIDDLEWARE = ( MIDDLEWARE_CLASSES = WHITENOISE_MIDDLEWARE + MIDDLEWARE_CLASSES {%- endif %} {% if cookiecutter.use_sentry == 'y' -%} -RAVEN_MIDDLEWARE = ('raven.contrib.django.raven_compat.middleware.Sentry404CatchMiddleware', - 'raven.contrib.django.raven_compat.middleware.SentryResponseErrorIdMiddleware',) +RAVEN_MIDDLEWARE = ( + 'raven.contrib.django.raven_compat.middleware.SentryResponseErrorIdMiddleware', +) MIDDLEWARE_CLASSES = RAVEN_MIDDLEWARE + MIDDLEWARE_CLASSES {%- endif %} From 0601795f6811bf4e33db836cf7abf76f4542b38e Mon Sep 17 00:00:00 2001 From: "Fabio C. Barrioneuvo da Luz" Date: Fri, 13 May 2016 00:13:17 -0300 Subject: [PATCH 11/22] update requirements and changelog --- CHANGELOG.md | 8 ++++++++ requirements.txt | 2 +- {{cookiecutter.project_slug}}/requirements/local.txt | 2 +- {{cookiecutter.project_slug}}/requirements/production.txt | 2 +- .../{{cookiecutter.project_slug}}/templates/base.html | 2 +- 5 files changed, 12 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7056d62cb..a643114b6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,14 @@ All enhancements and patches to Cookiecutter Django will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +## [2016-05-13] +### Changed +- Update version of pyflakes to 1.2.3, django-extensions to 1.6.7 and gunicorn to 19.5.0 (@luzfcb) +- Update version of AngularJS to 1.5.5 (@luzfcb) + +### Removed +- Remove Raven 404 catch middleware. Fix #367 (@pydanny) + ## [2016-05-09] ### Changed - Improved mailhog usage documentation on `developing-locally.rst` (@shireenrao) diff --git a/requirements.txt b/requirements.txt index 444c9fd35..d63bed873 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,6 +6,6 @@ binaryornot==0.4.0 # Testing pytest==2.9.1 pep8==1.7.0 -pyflakes==1.2.2 +pyflakes==1.2.3 tox==2.3.1 pytest-cookies==0.2.0 diff --git a/{{cookiecutter.project_slug}}/requirements/local.txt b/{{cookiecutter.project_slug}}/requirements/local.txt index 4711c0a3b..c88093fef 100644 --- a/{{cookiecutter.project_slug}}/requirements/local.txt +++ b/{{cookiecutter.project_slug}}/requirements/local.txt @@ -3,7 +3,7 @@ coverage==4.0.3 django_coverage_plugin==1.3 Sphinx -django-extensions==1.6.6 +django-extensions==1.6.7 Werkzeug==0.11.9 django-test-plus==1.0.12 factory_boy==2.7.0 diff --git a/{{cookiecutter.project_slug}}/requirements/production.txt b/{{cookiecutter.project_slug}}/requirements/production.txt index f6b1eaa30..b2308d363 100644 --- a/{{cookiecutter.project_slug}}/requirements/production.txt +++ b/{{cookiecutter.project_slug}}/requirements/production.txt @@ -12,7 +12,7 @@ psycopg2==2.6.1 # WSGI Handler # ------------------------------------------------ gevent==1.1.1 -gunicorn==19.4.5 +gunicorn==19.5.0 # Static and Media Storage # ------------------------------------------------ diff --git a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html index cd97ca6a2..b54692228 100644 --- a/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html +++ b/{{cookiecutter.project_slug}}/{{cookiecutter.project_slug}}/templates/base.html @@ -24,7 +24,7 @@ {% endblock %} {% endraw %}{% if cookiecutter.use_angular == "y" %}{% raw %}{% block angular %} - + {% endblock %}{% endraw %}{% endif %}{% raw %} From e206276269dfde1f1018de33e317133ae7c6d78d Mon Sep 17 00:00:00 2001 From: Dezoito Date: Sun, 15 May 2016 13:01:05 -0300 Subject: [PATCH 12/22] Added article to README.rst (#545) * Added fist version of gitlab ci file * Added Link to CI Integration in GitLab and name to contributor's list (Removed .gitlab-ci.yml due to issues building env in gitlab) --- CONTRIBUTORS.rst | 2 ++ README.rst | 2 ++ 2 files changed, 4 insertions(+) diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index a1cbdfc19..4fe615628 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -35,6 +35,7 @@ Listed in alphabetical order. ========================== ============================ ============== Name Github Twitter ========================== ============================ ============== + 18 `@dezoito`_ a7p `@a7p`_ Aaron Eikenberry `@aeikenberry`_ Adam Bogdał `@bogdal`_ @@ -112,6 +113,7 @@ Listed in alphabetical order. Yaroslav Halchenko ========================== ============================ ============== +.. _@dezoito: https://github.com/dezoito .. _@a7p: https://github.com/a7p .. _@ad-m: https://github.com/ad-m .. _@aeikenberry: https://github.com/aeikenberry diff --git a/README.rst b/README.rst index 4b4d3af15..1a8f860f0 100644 --- a/README.rst +++ b/README.rst @@ -217,6 +217,7 @@ Articles * `Development and Deployment of Cookiecutter-Django via Docker`_ - Dec. 29, 2015 * `How to create a Django Application using Cookiecutter and Django 1.8`_ - Sept. 12, 2015 * `Introduction to Cookiecutter-Django`_ - Feb. 19, 2016 +* `Django and GitLab - Running Continuous Integration and tests with your FREE account`_ - May. 11, 2016 Got a blog or online publication? Write about your cookiecutter-django tips and tricks, then send us a pull request with the link. @@ -224,6 +225,7 @@ Got a blog or online publication? Write about your cookiecutter-django tips and .. _`Development and Deployment of Cookiecutter-Django on Fedora`: https://realpython.com/blog/python/development-and-deployment-of-cookiecutter-django-on-fedora/ .. _`How to create a Django Application using Cookiecutter and Django 1.8`: http://blog.swapps.co/how-to-create-a-django-application-using-cookiecutter-and-django-1-8/#.VxKfBpMrKRs .. _`Introduction to Cookiecutter-Django`: http://krzysztofzuraw.com/blog/2016/django-cookiecutter.html +.. _`Django and GitLab - Running Continuous Integration and tests with your FREE account`: http://dezoito.github.io/2016/05/11/django-gitlab-continuous-integration-phantomjs.html Support This Project --------------------------- From b04e00f140f11574be6614bc652d4f32b89367e7 Mon Sep 17 00:00:00 2001 From: Daniel Roy Greenfeld Date: Sun, 15 May 2016 09:02:24 -0700 Subject: [PATCH 13/22] Added @dezoito's contribution to the changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index a643114b6..3b73e35f9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ All enhancements and patches to Cookiecutter Django will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +##[2016-05-15] +### Added +- Added GitLabl continuous integration article to README.rst (@dezoito) + ## [2016-05-13] ### Changed - Update version of pyflakes to 1.2.3, django-extensions to 1.6.7 and gunicorn to 19.5.0 (@luzfcb) From 779365c9f0009ef9dc19ef91bc5de6694af8a9e6 Mon Sep 17 00:00:00 2001 From: Audrey Roy Greenfeld Date: Tue, 17 May 2016 16:15:53 -0700 Subject: [PATCH 14/22] Clarify how ROOT_DIR is calculated --- {{cookiecutter.project_slug}}/config/settings/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.project_slug}}/config/settings/common.py b/{{cookiecutter.project_slug}}/config/settings/common.py index 292da8826..3668b4274 100644 --- a/{{cookiecutter.project_slug}}/config/settings/common.py +++ b/{{cookiecutter.project_slug}}/config/settings/common.py @@ -12,7 +12,7 @@ from __future__ import absolute_import, unicode_literals import environ -ROOT_DIR = environ.Path(__file__) - 3 # (/a/b/myfile.py - 3 = /) +ROOT_DIR = environ.Path(__file__) - 3 # ({{ cookiecutter.project_slug }}/config/settings/common.py - 3 = {{ cookiecutter.project_slug }}/) APPS_DIR = ROOT_DIR.path('{{ cookiecutter.project_slug }}') env = environ.Env() From 8795dacbb3dd88485a92157705bdaee6e3565364 Mon Sep 17 00:00:00 2001 From: phiberjenz Date: Thu, 19 May 2016 15:27:33 +0200 Subject: [PATCH 15/22] Added instructions on how to copy backups from Docker container to host --- docs/developing-locally-docker.rst | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/developing-locally-docker.rst b/docs/developing-locally-docker.rst index 8cbf72342..237e1a474 100644 --- a/docs/developing-locally-docker.rst +++ b/docs/developing-locally-docker.rst @@ -112,7 +112,13 @@ To restore a backup, run:: docker-compose -f dev.yml run postgres restore filename.sql +To copy the files from the running Postgres container to the host system:: + docker :/backups /host/path/target + +To get your Postgres container ID, run:: + + docker ps Other Useful Tips ----------------- From 82dae580612f18b8d352d435f0f6e71e4eba9077 Mon Sep 17 00:00:00 2001 From: phiberjenz Date: Thu, 19 May 2016 15:30:30 +0200 Subject: [PATCH 16/22] Added instructions on how to copy backups from Docker container to host --- docs/developing-locally-docker.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/developing-locally-docker.rst b/docs/developing-locally-docker.rst index 237e1a474..43e367c6e 100644 --- a/docs/developing-locally-docker.rst +++ b/docs/developing-locally-docker.rst @@ -114,9 +114,9 @@ To restore a backup, run:: To copy the files from the running Postgres container to the host system:: - docker :/backups /host/path/target + docker :/backups /host/path/target -To get your Postgres container ID, run:: +Where is the ID of the Postgres container. To get it, run:: docker ps From df9dc0f3ee79a84ef702cf9475323ddc3996f835 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A1bio=20C=2E=20Barrionuevo=20da=20Luz?= Date: Fri, 20 May 2016 21:37:14 -0300 Subject: [PATCH 17/22] add cookiecutter version warning in README.rst (#547) --- README.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.rst b/README.rst index 1a8f860f0..eece63919 100644 --- a/README.rst +++ b/README.rst @@ -16,6 +16,10 @@ Powered by Cookiecutter_, Cookiecutter Django is a framework for jumpstarting pr .. _cookiecutter: https://github.com/audreyr/cookiecutter +**Warning**: if you get the error "jinja2.exceptions.TemplateSyntaxError: Encountered unknown tag 'now'." , please upgrade your cookiecutter version to >= 1.4 (see issue # 528_ ) + +.. _528: https://github.com/pydanny/cookiecutter-django/issues/528#issuecomment-212650373 + Features --------- From 6c2063759cccf83433842c625f836a2f6b080137 Mon Sep 17 00:00:00 2001 From: Jannis Gebauer Date: Sun, 22 May 2016 20:20:57 +0200 Subject: [PATCH 18/22] added changes from @phiberjenz, @noisy --- CHANGELOG.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3b73e35f9..76ba8fba5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,9 +2,14 @@ All enhancements and patches to Cookiecutter Django will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). +##[2016-05-22] +### Added +- Added instructions for copying backups from docker to host (@phiberjenz) +- Added mailhog docker container (@noisy) + ##[2016-05-15] ### Added -- Added GitLabl continuous integration article to README.rst (@dezoito) +- Added GitLab continuous integration article to README.rst (@dezoito) ## [2016-05-13] ### Changed From 40fac2617575b1d39c30ee85aead45f5a74024ac Mon Sep 17 00:00:00 2001 From: Jannis Gebauer Date: Sun, 22 May 2016 20:21:58 +0200 Subject: [PATCH 19/22] added @phiberjenz --- CONTRIBUTORS.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index 4fe615628..129df2d6f 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -78,6 +78,7 @@ Listed in alphabetical order. Henrique G. G. Pereira `@ikkebr`_ Ian Lee `@IanLee1521`_ Jan Van Bruggen `@jvanbrug`_ + Jens Nilsson `@phiberjenz` Julio Castillo `@juliocc`_ Kaido Kert `@kaidokert`_ Kaveh `@ka7eh`_ From b21a27c1a51e97684f47b41817b2ba1f3f8c3037 Mon Sep 17 00:00:00 2001 From: Jannis Gebauer Date: Sun, 22 May 2016 20:23:53 +0200 Subject: [PATCH 20/22] fixed typo --- docs/developing-locally-docker.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/developing-locally-docker.rst b/docs/developing-locally-docker.rst index 43e367c6e..03e9221c5 100644 --- a/docs/developing-locally-docker.rst +++ b/docs/developing-locally-docker.rst @@ -114,7 +114,7 @@ To restore a backup, run:: To copy the files from the running Postgres container to the host system:: - docker :/backups /host/path/target + docker cp :/backups /host/path/target Where is the ID of the Postgres container. To get it, run:: From 6915c2c89a2ce6f75b4b0bea7672d98b7e5e4bc8 Mon Sep 17 00:00:00 2001 From: Jannis Gebauer Date: Sun, 22 May 2016 20:50:07 +0200 Subject: [PATCH 21/22] removed repo_name references --- {{cookiecutter.project_slug}}/.gitignore | 3 --- 1 file changed, 3 deletions(-) diff --git a/{{cookiecutter.project_slug}}/.gitignore b/{{cookiecutter.project_slug}}/.gitignore index a1f2fc276..f2d14296f 100644 --- a/{{cookiecutter.project_slug}}/.gitignore +++ b/{{cookiecutter.project_slug}}/.gitignore @@ -68,9 +68,6 @@ node_modules/ # User-uploaded media {{ cookiecutter.project_slug }}/media/ -======= -{{ cookiecutter.repo_name }}/media/ - # Hitch directory tests/.hitch {% if cookiecutter.use_mailhog == 'y' and cookiecutter.use_docker == 'n'%} From 3717cbb6aaa841a60b8b477b3061c0cd2efc502e Mon Sep 17 00:00:00 2001 From: Eman Calso Date: Tue, 24 May 2016 05:46:34 +0800 Subject: [PATCH 22/22] Install python3-dev when not using python2 (#551) * Install python3-dev if use_python2==n By default, ubuntu-based distros would install python2-dev if you install python-dev. python3-dev should be installed explicitly if we're not using python2. * Add Emanuel Calso to contributors --- CONTRIBUTORS.rst | 2 ++ {{cookiecutter.project_slug}}/utility/requirements.apt | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/CONTRIBUTORS.rst b/CONTRIBUTORS.rst index 129df2d6f..2fda7c634 100644 --- a/CONTRIBUTORS.rst +++ b/CONTRIBUTORS.rst @@ -69,6 +69,7 @@ Listed in alphabetical order. Davur Clementsen `@dsclementsen`_ @davur Dónal Adams `@epileptic-fish`_ Dong Huynh `@trungdong`_ + Emanuel Calso `@bloodpet`_ @bloodpet Eraldo Energy `@eraldo`_ Eyad Al Sibai `@eyadsibai`_ Felipe Arruda `@arruda`_ @@ -123,6 +124,7 @@ Listed in alphabetical order. .. _@andor-pierdelacabeza: https://github.com/andor-pierdelacabeza .. _@areski: https://github.com/areski .. _@arruda: https://github.com/arruda +.. _@bloodpet: https://github.com/bloodpet .. _@bogdal: https://github.com/bogdal .. _@burhan: https://github.com/burhan .. _@c-rhodes: https://github.com/c-rhodes diff --git a/{{cookiecutter.project_slug}}/utility/requirements.apt b/{{cookiecutter.project_slug}}/utility/requirements.apt index 2fb764c3d..9a18d50d4 100644 --- a/{{cookiecutter.project_slug}}/utility/requirements.apt +++ b/{{cookiecutter.project_slug}}/utility/requirements.apt @@ -3,7 +3,11 @@ build-essential #required to translate gettext +{% if cookiecutter.use_python2 == 'n' -%} +python3-dev +{% else %} python-dev +{%- endif %} ##shared dependencies of: ##Pillow, pylibmc