Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Clean out files in a django app using regular expressions.

Project Description
django-clean
====================

django-clean is a package that lets you specify files or directories that you
would like cleaned up. You can specify regular expressions to define which
files you would like automatically removed.


Installation
------------
1. Add 'clean' to your installed apps in your settings.py file.

INSTALLED_APPS = [
'clean',
...
]


2. Define a PROJECT_PATH in your settings.py file.

import os.path, sys
PROJECT_PATH = os.path.dirname(__file__)


3. *OPTIONAL* Define the regular expression patterns you would like to match against in
your settings.py file. The default is a regex pattern to remove *.pyc files. (NOTE: The
regex matches against the full qualified path).

CLEAN_PATTERNS = [
r'^.+\.pyc$',
]


Usage
-----
From your shell, type:

python manage.py clean

This will prompt you to remove files that match the regular expression patterns.

If you are confident in your regex, you can supply a --force option which will not prompt
you before removing pattern matches.
Release History

Release History

This version
History Node

0.1.2

History Node

0.1.1

History Node

0.1.0

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
django-clean-0.1.2.tar.gz (3.8 kB) Copy SHA256 Checksum SHA256 Source Dec 24, 2011

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting