summaryrefslogtreecommitdiff
path: root/django/contrib/staticfiles/utils.py
AgeCommit message (Collapse)Author
2022-02-07Refs #33476 -- Reformatted code with Black.django-bot
2022-02-03Refs #33476 -- Refactored problematic code before reformatting by Black.Mariusz Felisiak
In these cases Black produces unexpected results, e.g. def make_random_password( self, length=10, allowed_chars='abcdefghjkmnpqrstuvwxyz' 'ABCDEFGHJKLMNPQRSTUVWXYZ' '23456789', ): or cursor.execute(""" SELECT ... """, [table name], )
2020-03-19Removed unused default value None to matches_patterns().Jon Dufresne
An iterable is always passed.
2018-08-23Fixed #29570 -- Added check that MEDIA_URL isn't in STATIC_URL.Alejandro Dubrovsky
2018-07-13Fixed #28566 -- Added path matching to collectstatic ignore patterns.Daniel Wiesmann
2017-12-26Fixed #28930 -- Simplified code with any() and all().Дилян Палаузов
2017-02-23Refs #23919 -- Used yield from.Vytis Banaitis
2017-02-04Refs #27656 -- Updated django.contrib docstring verb style according to PEP 257.Anton Samarchyan
2015-08-31Fixed #25331 -- Removed trailing blank lines in docstrings.Maxime Lorant
2015-02-06Sorted imports with isort; refs #23860.Tim Graham
2013-11-02More attacking E302 violatorsAlex Gaynor
2011-08-15Fixed #16631 -- Fixed embarrassing typo introduced in r16617. Thanks, Andi ↵Jannis Leidel
Albrecht. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16618 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-14Fixed #16629 -- Relaxed check for STATIC_ROOT and STATIC_URL settings ↵Jannis Leidel
slightly to only raise an exception if really needed. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16617 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-11Fixed #15252 -- Added static template tag and CachedStaticFilesStorage to ↵Jannis Leidel
staticfiles contrib app. Many thanks to Florian Apolloner and Jacob Kaplan-Moss for reviewing and eagle eyeing. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16594 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-01Fixed #15094 - Added check for forgetting trailing comma in STATICFILES_DIRS ↵Carl Meyer
tuple. Also reorganized staticfiles settings-checks for better consistency. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15386 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-30Added check to the staticfiles app to make sure the STATIC_ROOT setting ↵Jannis Leidel
isn't accidentally added to the STATICFILES_DIRS setting. Thanks for the suggestion, SmileyChris and harijay. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15376 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-15Stopped staticfiles app from requiring a models module when looking for ↵Jannis Leidel
static files. Also removed a bit of code smell in the prefix handling by saving it in the source file storage. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15219 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-02Fixed #14998 -- Made use of os.path.join to make sure this works on all ↵Jannis Leidel
platforms. Thanks for the pointer, CarlFK. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15128 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-11-17Fixed #14693, #14709 -- Backwards incompatible change to rectify the ↵Jannis Leidel
confusion around the STATICFILES_URL and STATICFILES_ROOT settings. * Two new global settings that will be used by -- **but are not limited to** -- the staticfiles app: STATIC_ROOT and STATIC_URL. * Moving the 'django.contrib.staticfiles.templatetags.staticfiles' template tag to the core ('django.templatetags.static') and renaming it to 'get_static_prefix'. * Moving the context processor 'django.contrib.staticfiles.context_processors.staticfiles' to the core ('django.core.context_processors.static') and renaming it to 'static'. * Paths in media definitions will use STATIC_URL as the prefix if the value is not None, and falls back to the previously used MEDIA_URL. Thanks again to the community for constructive criticism and Carl and Russ for sanity-inducing discussions on IRC. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14592 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-11-11Fixed #14524, #14582, #14617, #14665 and #14667 -- Tweaked staticfiles app.Jannis Leidel
* Updated StaticFilesHandler and AdminMediaHandler to make use of the 404 handler if needed. * Updated runserver management command to serve static files only in DEBUG mode (or if specified the --insecure option) and if the staticfiles app is in INSTALLED_APPS. Also added an option to disable serving completely (--nostatic). * Added check in debug mode if STATICFILES_* settings are different to MEDIA_* settings. * Removed a faulty PendingDeprecationWarning in AdminMediaHandler that is triggered every time runserver is used. * Fixed an issue with the modification time checks when running collectstatic. * Extended and refined documentation. Thanks to everyone for input, especially to Carl Meyer, Ted Kaemming and Adam Vandenberg for patches. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-10-20Fixed #12323 and #11582 -- Extended the ability to handle static files. ↵Jannis Leidel
Thanks to all for helping with the original app, the patch, documentation and general support. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14293 bcc190cf-cafb-0310-a4f2-bffc1f526a37