public
Description: The source code for the Django Plugables application index.
Homepage: http://djangoplugables.com/
Clone URL: git://github.com/revyver/django-plugables.git
Search Repo:
Adding the project of the hour, djangopluggables.com to central command.

git-svn-id: 
http://svn.revyver.com/djangopluggables.com/trunk/applications@191 
5c07df8f-9e68-4da1-b9d9-3219ff5d644b
revyver (author)
Sat Apr 05 19:05:29 -0700 2008
commit  eccd8d3e19b2a5a06db0367dd778c0dcb2ee04cf
tree    71be5a57aa4450a2df2b659981e1f71554cb23c7
...
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
0
@@ -0,0 +1,13 @@
0
+from django.contrib import admin
0
+
0
+from models import Item
0
+
0
+
0
+class ItemAdmin(admin.ModelAdmin):
0
+ date_hierarchy = 'timestamp'
0
+ list_display = ('timestamp', 'object_str')
0
+ list_filter = ('content_type', 'timestamp')
0
+ search_fields = ('object_str', 'tags')
0
+
0
+
0
+admin.site.register(Item, ItemAdmin)
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
0
@@ -0,0 +1,101 @@
0
+import datetime
0
+
0
+from django.db import models
0
+from django.db.models import signals
0
+from django.dispatch import dispatcher
0
+from django.contrib.contenttypes.models import ContentType
0
+
0
+from tagging.fields import TagField
0
+
0
+
0
+class ItemManager(models.Manager):
0
+
0
+ def __init__(self):
0
+ self.models_by_name = {}
0
+
0
+ def create_or_update(self, instance, timestamp=None, tags="", source="INTERACTIVE", source_id=""):
0
+ """
0
+ Create or update an Item from some instace.
0
+ """
0
+ # If the instance hasn't already been saved, save it first. This
0
+ # requires disconnecting the post-save signal that might be sent to
0
+ # this function (otherwise we could get an infinite loop).
0
+ if instance._get_pk_val() is None:
0
+ try:
0
+ dispatcher.disconnect(self.create_or_update, signal=signals.post_save, sender=type(instance))
0
+ except dispatcher.errors.DispatcherError:
0
+ reconnect = False
0
+ else:
0
+ reconnect = True
0
+ instance.save()
0
+ if reconnect:
0
+ dispatcher.connect(self.create_or_update, signal=signals.post_save, sender=type(instance))
0
+
0
+ # Make sure the item "should" be registered.
0
+ if not getattr(instance, "jellyrollable", True):
0
+ return
0
+
0
+ # Check to see if the timestamp is being updated, possibly pulling
0
+ # the timestamp from the instance.
0
+ if hasattr(instance, "timestamp"):
0
+ timestamp = instance.timestamp
0
+ if timestamp is None:
0
+ update_timestamp = False
0
+ timestamp = datetime.datetime.now()
0
+ else:
0
+ update_timestamp = True
0
+
0
+ # Ditto for tags.
0
+ if not tags:
0
+ for f in instance._meta.fields:
0
+ if isinstance(f, TagField):
0
+ tags = getattr(instance, f.attname)
0
+ break
0
+
0
+ # Create the Item object.
0
+ ctype = ContentType.objects.get_for_model(instance)
0
+ item, created = self.get_or_create(
0
+ content_type = ctype,
0
+ object_id = instance._get_pk_val(),
0
+ defaults = dict(
0
+ timestamp = timestamp,
0
+ source = source,
0
+ source_id = source_id,
0
+ tags = tags,
0
+ )
0
+ )
0
+ item.tags = tags
0
+ item.source = source
0
+ item.source_id = source_id
0
+ if update_timestamp:
0
+ item.timestamp = timestamp
0
+
0
+ # Save and return the item.
0
+ item.save()
0
+ return item
0
+
0
+ def follow_model(self, model):
0
+ """
0
+ Follow a particular model class, updating associated Items automatically.
0
+ """
0
+ self.models_by_name[model.__name__.lower()] = model
0
+ dispatcher.connect(self.create_or_update, signal=signals.post_save, sender=model)
0
+
0
+ def get_for_model(self, model):
0
+ """
0
+ Return a QuerySet of only items of a certain type.
0
+ """
0
+ return self.filter(content_type=ContentType.objects.get_for_model(model))
0
+
0
+ def get_last_update_of_model(self, model, **kwargs):
0
+ """
0
+ Return the last time a given model's items were updated. Returns the
0
+ epoch if the items were never updated.
0
+ """
0
+ qs = self.get_for_model(model)
0
+ if kwargs:
0
+ qs = qs.filter(**kwargs)
0
+ try:
0
+ return qs.order_by('-timestamp')[0].timestamp
0
+ except IndexError:
0
+ return datetime.datetime.fromtimestamp(0)
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
0
@@ -0,0 +1,54 @@
0
+from django.db import models
0
+from django.contrib.contenttypes.models import ContentType
0
+from django.contrib.contenttypes.generic import GenericForeignKey
0
+
0
+from managers import ItemManager
0
+from tagging.fields import TagField
0
+
0
+
0
+class Item(models.Model):
0
+ """
0
+ A generic item used to tie the objects to the respective data provider.
0
+ """
0
+
0
+ # Generic relation to the object.
0
+ content_type = models.ForeignKey(ContentType)
0
+ object_id = models.TextField()
0
+ object = GenericForeignKey()
0
+
0
+ # "Standard" metadata each object provides.
0
+ url = models.URLField(blank=True)
0
+ timestamp = models.DateTimeField()
0
+ tags = TagField()
0
+
0
+ # Metadata about where the object "came from" -- used by data providers to
0
+ # figure out which objects to update when asked.
0
+ source = models.CharField(max_length=100, blank=True)
0
+ source_id = models.TextField(blank=True)
0
+
0
+ # Denormalized object __str__, for performance
0
+ object_str = models.TextField(blank=True)
0
+
0
+ objects = ItemManager()
0
+
0
+ class Meta:
0
+ ordering = ['-timestamp']
0
+ unique_together = [('content_type', 'object_id')]
0
+
0
+ def __str__(self):
0
+ return "%s: %s" % (self.content_type.model_class().__name__, self.object_str)
0
+
0
+ def __cmp__(self, other):
0
+ return cmp(self.timestamp, other.timestamp)
0
+
0
+ def save(self):
0
+ ct = '%s %s' % (self.content_type.app_label, self.content_type.model.lower())
0
+ self.object_str = str(self.object)
0
+ if hasattr(self.object, 'url'):
0
+ self.url = self.object.url
0
+ super(Item, self).save()
0
+
0
+
0
+# Initilization
0
+from core import register
0
+del register
...
 
 
0
...
1
2
3
0
@@ -0,0 +1,2 @@
0
+# Administration
0
+from core import admin
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
0
@@ -0,0 +1,11 @@
0
+#!/usr/bin/env python
0
+from django.core.management import execute_manager
0
+try:
0
+ import settings # Assumed to be in the same directory.
0
+except ImportError:
0
+ import sys
0
+ sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n(If the file settings.py does indeed exist, it's causing an ImportError somehow.)\n" % __file__)
0
+ sys.exit(1)
0
+
0
+if __name__ == "__main__":
0
+ execute_manager(settings)
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
0
@@ -0,0 +1,33 @@
0
+from django.contrib import admin
0
+
0
+from models import Project, Maintainer, CodeRepository, CodeCommit
0
+
0
+
0
+class ProjectAdmin(admin.ModelAdmin):
0
+ list_display = ('name', 'type', 'url')
0
+ search_fields = ('name', 'description')
0
+ prepopulated_fields = { 'slug': ('name',) }
0
+
0
+
0
+class MaintainerAdmin(admin.ModelAdmin):
0
+ list_display = ('full_name',)
0
+ search_fields = ('last_name', 'first_name', 'bio')
0
+ prepopulated_fields = { 'slug': ('first_name', 'middle_name', 'last_name', 'suffix') }
0
+
0
+
0
+class CodeRepositoryAdmin(admin.ModelAdmin):
0
+ list_display = ('name', 'type', 'url')
0
+ search_fields = ('',)
0
+ prepopulated_fields = { 'slug': ('name',) }
0
+
0
+
0
+class CodeCommitAdmin(admin.ModelAdmin):
0
+ list_display = ('__unicode__', 'repository')
0
+ list_filter = ('repository',)
0
+ search_fields = ('message',)
0
+
0
+
0
+admin.site.register(Project, ProjectAdmin)
0
+admin.site.register(Maintainer, MaintainerAdmin)
0
+admin.site.register(CodeRepository, CodeRepositoryAdmin)
0
+admin.site.register(CodeCommit, CodeCommit)
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
0
@@ -0,0 +1,145 @@
0
+from django.db import models
0
+
0
+from core.models import Item
0
+from tagging.fields import TagField
0
+
0
+
0
+class Project(models.Model):
0
+ """
0
+ A project is a wrapper around a code repository, connecting authors and
0
+ other descriptive information to it.
0
+ """
0
+
0
+ name = models.CharField(max_length=100)
0
+ description = models.TextField(help_text='A short description of the project.')
0
+ repository = models.ForeignKey('CodeRepository', related_name='repository')
0
+ maintainers = models.ManyToManyField('Maintainer', related_name='maintainer')
0
+ slug = models.SlugField(unique=True)
0
+ url = models.URLField(verify_exists=True, help_text='The URL to the project, usually hosted at Google Code.')
0
+ tags = TagField()
0
+
0
+ def __unicode__(self):
0
+ return self.name
0
+
0
+ @permalink
0
+ def get_absolute_url(self):
0
+ return ('project-detail', (), {
0
+ 'slug': self.slug
0
+ })
0
+
0
+
0
+class Maintainer(models.Model):
0
+ """
0
+ A maintainer is a person with commmit rights to a given code repository.
0
+ All this model contains is simple metadata, if available.
0
+ """
0
+
0
+ # Basics
0
+ first_name = models.CharField(max_length=200)
0
+ middle_name = models.CharField(max_length=200, blank=True)
0
+ last_name = models.CharField(max_length=200)
0
+ suffix = models.CharField(max_length=100, blank=True)
0
+ bio = models.TextField(blank=True)
0
+ slug = models.SlugField(unique=True)
0
+
0
+ # URLs
0
+ personal_url = models.URLField(blank=True, verify_exists=True)
0
+ professional_url = models.URLField(blank=True, verify_exists=True)
0
+
0
+ class Meta:
0
+ ordering = ('last_name', 'first_name')
0
+
0
+ def __unicode__(self):
0
+ return self.name
0
+
0
+ @permalink
0
+ def get_absolute_url(self):
0
+ return ('maintainer-detail', (), {
0
+ 'slug': self.slug
0
+ })
0
+
0
+ @property
0
+ def name(self):
0
+ if self.first_name or self.last_name:
0
+ return ' '.join(b for b in (self.first_name, self.last_name) if b)
0
+
0
+ @property
0
+ def full_name(self):
0
+ return ' '.join(b for b in (self.first_name, self.middle_name, self.last_name, self.suffix) if b)
0
+
0
+ def get_projects(self):
0
+ """
0
+ Returns a string of projects for use in the admin list display.
0
+ """
0
+
0
+ maintainers = Project.objects.filter(maintainers=self)
0
+ projects = []
0
+ for maintainer in maintainers:
0
+ projects.append(str(project.name))
0
+ return ', '.join(projects)
0
+
0
+
0
+class CodeRepository(models.Model):
0
+ """
0
+ A code repository that you check code into somewhere. Currently only SVN
0
+ is supported, but other forms should be hard to support.
0
+ """
0
+
0
+ SCM_CHOICES = (
0
+ ('svn', 'Subversion'),
0
+ )
0
+
0
+ type = models.CharField(max_length=3, choices=SCM_CHOICES, default='svn')
0
+ name = models.CharField(max_length=100)
0
+ slug = models.SlugField(unique=True)
0
+ username = models.CharField(max_length=100, help_text='The maintainer\'s username for this SCR.')
0
+ public_changeset_template = models.URLField(verify_exists=False, blank=True, help_text='Template for viewing a changeset publically. Use \'%s\' for the revision number')
0
+ url = models.URLField(verify_exists=True)
0
+
0
+ class Meta:
0
+ verbose_name_plural = 'code repositories'
0
+
0
+ def __unicode__(self):
0
+ return self.name
0
+
0
+ @permalink
0
+ def get_absolute_url(self):
0
+ return ('repository-detail', (), {
0
+ 'slug': self.slug
0
+ })
0
+
0
+ def updated(self):
0
+ commits = CodeCommit.objects.filter('-committed')[:0]
0
+ last_commit = commits.committed
0
+ return last_commit
0
+
0
+
0
+class CodeCommit(models.Model):
0
+ """
0
+ A code change that's been checked in.
0
+ """
0
+
0
+ repository = models.ForeignKey(CodeRepository, related_name='commits')
0
+ revision = models.PositiveSmallIntegerField()
0
+ message = models.TextField()
0
+ committed = models.DateTimeField()
0
+
0
+ class Meta:
0
+ ordering = ['-revision']
0
+
0
+ def __unicode__(self):
0
+ return "[%s] %s" % (self.revision, text.truncate_words(self.message, 10))
0
+
0
+ @property
0
+ def url(self):
0
+ if self.repository.public_changeset_template:
0
+ return self.repository.public_changeset_template % self.revision
0
+ return ""
0
+
0
+
0
+# Initilization
0
+from projects import register
0
+del register
0
+
0
+# Register item objects to be "followed"
0
+Item.objects.follow_model(CodeCommit)
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
0
@@ -0,0 +1,56 @@
0
+import time
0
+import logging
0
+import datetime
0
+
0
+from django.db import transaction
0
+from django.utils.encoding import smart_unicode
0
+
0
+from core.models import Item
0
+from projects.models import Item, CodeRepository, CodeCommit
0
+from projects.providers import utils
0
+
0
+
0
+try:
0
+ import pysvn
0
+except ImportError:
0
+ pysvn = None
0
+
0
+log = logging.getLogger("jellyroll.providers.svn")
0
+
0
+#
0
+# Public API
0
+#
0
+def enabled():
0
+ return pysvn is not None
0
+
0
+def update():
0
+ for repository in CodeRepository.objects.filter(type="svn"):
0
+ _update_repository(repository)
0
+
0
+#
0
+# Private API
0
+#
0
+
0
+def _update_repository(repository):
0
+ source_identifier = "%s:%s" % (__name__, repository.url)
0
+ last_update_date = Item.objects.get_last_update_of_model(CodeCommit, source=source_identifier)
0
+ log.info("Updating changes from %s since %s", repository.url, last_update_date)
0
+ rev = pysvn.Revision(pysvn.opt_revision_kind.date, time.mktime(last_update_date.timetuple()))
0
+ c = pysvn.Client()
0
+ for revision in reversed(c.log(repository.url, revision_end=rev)):
0
+ _handle_revision(repository, revision)
0
+
0
+@transaction.commit_on_success
0
+def _handle_revision(repository, r):
0
+ log.debug("Handling [%s] from %s" % (r.revision.number, repository.url))
0
+ ci, created = CodeCommit.objects.get_or_create(
0
+ revision = r.revision.number,
0
+ repository = repository,
0
+ committed = datetime.datetime.fromtimestamp(r.date),
0
+ defaults = {"message": smart_unicode(r.message)}
0
+ )
0
+ return Item.objects.create_or_update(
0
+ instance = ci,
0
+ timestamp = datetime.datetime.fromtimestamp(r.date),
0
+ source = "%s:%s" % (__name__, repository.url),
0
+ )
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
0
@@ -0,0 +1,35 @@
0
+"""
0
+Get an Etree library. Usage::
0
+
0
+ >>> from anyetree import etree
0
+
0
+Returns some etree library. Looks for (in order of decreasing preference):
0
+
0
+ * ``lxml.etree`` (http://cheeseshop.python.org/pypi/lxml/)
0
+ * ``xml.etree.cElementTree`` (built into Python 2.5)
0
+ * ``cElementTree`` (http://effbot.org/zone/celementtree.htm)
0
+ * ``xml.etree.ElementTree`` (built into Python 2.5)
0
+ * ``elementree.ElementTree (http://effbot.org/zone/element-index.htm)
0
+"""
0
+
0
+__all__ = ['etree']
0
+
0
+SEARCH_PATHS = [
0
+ "lxml.etree",
0
+ "xml.etree.cElementTree",
0
+ "cElementTree",
0
+ "xml.etree.ElementTree",
0
+ "elementtree.ElementTree",
0
+]
0
+
0
+etree = None
0
+
0
+for name in SEARCH_PATHS:
0
+ try:
0
+ etree = __import__(name, '', '', [''])
0
+ break
0
+ except ImportError:
0
+ continue
0
+
0
+if etree is None:
0
+ raise ImportError("No suitable ElementTree implementation found.")
0
\ No newline at end of file
...
 
 
0
...
1
2
3
0
@@ -0,0 +1,2 @@
0
+# Administration
0
+from scr import admin
0
\ No newline at end of file
...
 
...
1
0
@@ -0,0 +1 @@
0
+# Create your views here.
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
0
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
0
@@ -0,0 +1,83 @@
0
+# Django settings for applications project.
0
+
0
+DEBUG = True
0
+TEMPLATE_DEBUG = DEBUG
0
+
0
+ADMINS = (
0
+ # ('Your Name', 'your_email@domain.com'),
0
+)
0
+
0
+MANAGERS = ADMINS
0
+
0
+DATABASE_ENGINE = '' # 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
0
+DATABASE_NAME = '' # Or path to database file if using sqlite3.
0
+DATABASE_USER = '' # Not used with sqlite3.
0
+DATABASE_PASSWORD = '' # Not used with sqlite3.
0
+DATABASE_HOST = '' # Set to empty string for localhost. Not used with sqlite3.
0
+DATABASE_PORT = '' # Set to empty string for default. Not used with sqlite3.
0
+
0
+# Local time zone for this installation. Choices can be found here:
0
+# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
0
+# although not all choices may be available on all operating systems.
0
+# If running in a Windows environment this must be set to the same as your
0
+# system time zone.
0
+TIME_ZONE = 'America/Los_Angeles'
0
+
0
+# Language code for this installation. All choices can be found here:
0
+# http://www.i18nguy.com/unicode/language-identifiers.html
0
+LANGUAGE_CODE = 'en-us'
0
+
0
+SITE_ID = 1
0
+
0
+# If you set this to False, Django will make some optimizations so as not
0
+# to load the internationalization machinery.
0
+USE_I18N = True
0
+
0
+# Absolute path to the directory that holds media.
0
+# Example: "/home/media/media.lawrence.com/"
0
+MEDIA_ROOT = ''
0
+
0
+# URL that handles the media served from MEDIA_ROOT. Make sure to use a
0
+# trailing slash if there is a path component (optional in other cases).
0
+# Examples: "http://media.lawrence.com", "http://example.com/media/"
0
+MEDIA_URL = ''
0
+
0
+# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a
0
+# trailing slash.
0
+# Examples: "http://foo.com/media/", "/media/".
0
+ADMIN_MEDIA_PREFIX = '/media/'
0
+
0
+# Make this unique, and don't share it with anybody.
0
+SECRET_KEY = 'x7^nmggd5rhs2zl!cw%v7it)nmx!8b&i$i73370tj^axbv6u2w'
0
+
0
+# List of callables that know how to import templates from various sources.
0
+TEMPLATE_LOADERS = (
0
+ 'django.template.loaders.filesystem.load_template_source',
0
+ 'django.template.loaders.app_directories.load_template_source',
0
+# 'django.template.loaders.eggs.load_template_source',
0
+)
0
+
0
+MIDDLEWARE_CLASSES = (
0
+ 'django.middleware.common.CommonMiddleware',
0
+ 'django.contrib.sessions.middleware.SessionMiddleware',
0
+ 'django.contrib.auth.middleware.AuthenticationMiddleware',
0
+ 'django.middleware.doc.XViewMiddleware',
0
+)
0
+
0
+ROOT_URLCONF = 'applications.urls'
0
+
0
+TEMPLATE_DIRS = (
0
+ # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates".
0
+ # Always use forward slashes, even on Windows.
0
+ # Don't forget to use absolute paths, not relative paths.
0
+)
0
+
0
+INSTALLED_APPS = (
0
+ 'django.contrib.auth',
0
+ 'django.contrib.contenttypes',
0
+ 'django.contrib.sessions',
0
+ 'django.contrib.sites',
0
+)
0
+
0
+# Import Local Settings
0
+from pluggables import *
0
\ No newline at end of file
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
0
@@ -0,0 +1,15 @@
0
+from django.conf.urls.defaults import *
0
+
0
+# Uncomment this for admin:
0
+#from django.contrib import admin
0
+
0
+urlpatterns = patterns('',
0
+ # Example:
0
+ # (r'^applications/', include('applications.foo.urls')),
0
+
0
+ # Uncomment this for admin docs:
0
+ #(r'^admin/doc/', include('django.contrib.admindocs.urls')),
0
+
0
+ # Uncomment this for admin:
0
+ #('^admin/(.*)', admin.site.root),
0
+)

Comments

    No one has commented yet.