diff --git a/.gitignore b/.gitignore index 1a060977..6ccee3a8 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ env/* *.sqlite custom_settings.py *.kdev4* +env diff --git a/.project b/.project new file mode 100644 index 00000000..e4c5b736 --- /dev/null +++ b/.project @@ -0,0 +1,19 @@ + + + agora-ciudadana + + + agora-ciudadana + + + + org.python.pydev.PyDevBuilder + + + + + + org.python.pydev.pythonNature + org.python.pydev.django.djangoNature + + diff --git a/.pydevproject b/.pydevproject new file mode 100644 index 00000000..8d0d8146 --- /dev/null +++ b/.pydevproject @@ -0,0 +1,14 @@ + + + + + +DJANGO_MANAGE_LOCATION +manage.py + +Default +python 2.7 + +/agora-ciudadana + + diff --git a/README b/README new file mode 100644 index 00000000..25fd1319 --- /dev/null +++ b/README @@ -0,0 +1,22 @@ +To work on the project you just need these packages installed on your computer: + + python 2.7+ + python-virtualenv + python-pip + +if all those are installed just 'cd' to the project folder and execute: + + mkdir env + virtualenv env + source env/bin/activate + ./setup_env.sh + + +virtualenv will create a python enviroment for this project +./setup_env will download all dependencies and install them locally (no need for root privileges) just for the project + +to create the database: + ./manage.py syncdb +to test the webapp and then browse to http://localhost:8000 + ./manage.py runserver 127.0.0.1:8000 + diff --git a/agora/__init__.py b/agora/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/agora/models.py b/agora/models.py new file mode 100644 index 00000000..71a83623 --- /dev/null +++ b/agora/models.py @@ -0,0 +1,3 @@ +from django.db import models + +# Create your models here. diff --git a/agora/tests.py b/agora/tests.py new file mode 100644 index 00000000..501deb77 --- /dev/null +++ b/agora/tests.py @@ -0,0 +1,16 @@ +""" +This file demonstrates writing tests using the unittest module. These will pass +when you run "manage.py test". + +Replace this with more appropriate tests for your application. +""" + +from django.test import TestCase + + +class SimpleTest(TestCase): + def test_basic_addition(self): + """ + Tests that 1 + 1 always equals 2. + """ + self.assertEqual(1 + 1, 2) diff --git a/agora/views.py b/agora/views.py new file mode 100644 index 00000000..60f00ef0 --- /dev/null +++ b/agora/views.py @@ -0,0 +1 @@ +# Create your views here. diff --git a/settings.py b/settings.py index 0cbc66fa..cff2b266 100644 --- a/settings.py +++ b/settings.py @@ -1,5 +1,7 @@ # Django settings for votering project. +import os + DEBUG = True TEMPLATE_DEBUG = DEBUG @@ -87,7 +89,6 @@ ROOT_URLCONF = 'urls' -import os ROOT_PATH = os.path.dirname(__file__) TEMPLATE_DIRS = ( os.path.join(ROOT_PATH, 'templates'), @@ -112,4 +113,4 @@ # settings file from custom_settings import * except: - pass \ No newline at end of file + pass diff --git a/templates/base.html b/templates/base.html index 6b821b45..8fdd721a 100644 --- a/templates/base.html +++ b/templates/base.html @@ -3,128 +3,128 @@ - - - - {{ SITE_NAME }} - {% block title %}{% trans "Home" %}{% endblock %} + + + + {{ SITE_NAME }} - {% block title %}{% trans "Home" %}{% endblock %} -
-