Commits

Dmitri Lebedev committed 175c70f

refactored makefile to avoid excessive rebuilding

Comments (0)

Files changed (3)

-# Just remember that you need to use real tabs, not spaces, in a Makefile
-
 # Just remember that you need to use real tabs, not spaces, in a Makefile
 
 .PHONY: run
-run: bin/django
-	bin/django runserver 0.0.0.0:8008
+run: bin/django syncdb bin/sass
+	bin/django runserver 0.0.0.0:8000
 
 .PHONY: shell_plus
-shell_plus: bin/django
+shell_plus: bin/django syncdb bin/sass
 	bin/django shell_plus
 
-.PHONY: pyflakes
-pyflakes:
+.PHONY: check_pyflakes
+check_pyflakes: bin/pyflakes
 	find velo -name '*.py' -exec pyflakes {} \;
 
+bin/pyflakes: bin/buildout
+	bin/buildout install pyflakes
+
 bin/django: bin/buildout
 	bin/buildout
 
-bin/buildout: bootstrap.py
+bin/buildout:
 	python bootstrap.py --distribute
 
-init: bin/django
+syncdb: bin/django
 	bin/django syncdb
+	# touch a timestamp file to avoid re-syncing
+	touch syncdb  
 
 .PHONY: make_trans
-make_trans:
+make_trans: bin/django
 	bin/django makemessages -a -e 'html,haml'
 
 .PHONY: compile_trans
-compile_trans:
+compile_trans: bin/django
 	bin/django compilemessages
+
+bin/sass: bin/buildout
+	bin/buildout install sass
 # hamlpy needs a patch that this subrepo has
 parts =
 	django
-	rubygems
-	pyflakes
 	pep8
 	cleanup
 
 	hamlpy                # HAML templates. Before a pull request is done, culebron-hamlpy is used.
 	djaml                 # hamlpy loader
 
-[rubygems]
+[sass]
 recipe = rubygemsrecipe
 gems =
 	sass
 project = ${buildout:project}
 
 [versions]
-
 # change these versions when you are sure they will be compatible with your project
 django = 1.3.1
 django-reversion = 1.5.1

project/settings.py

 
 DATABASES = {
 	'default': {
-		'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
-		'NAME': '',					  # Or path to database file if using sqlite3.
+		'ENGINE': 'django.db.backends.sqlite3', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
+		'NAME': 'development',					  # Or path to database file if using sqlite3.
 		'USER': '',					  # Not used with sqlite3.
 		'PASSWORD': '',				  # Not used with sqlite3.
 		'HOST': '',					  # Set to empty string for localhost. Not used with sqlite3.