TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Django settings template

39 pointsby va1en0kabout 14 years ago

5 comments

philipkimmeyabout 14 years ago
This is remarkably similar to how I setup my Django settings.py files. The only thing I'd add is I like to have a lib folder and do a sys.path.insert(0, PATH/TO/Lib/Folder) in my manage.py and .wsgi files. This makes it really easy to manage dependencies. The other option is to use virtualenv, but in my experience it falls down pretty hard on modules that require C bindings, so why not just manage it manually? In addition, if you use git, you can take advantage of git's submodule functionality to really easily keep track of specific versions of your submodules.<p>I was actually in the middle of a similar writeup that includes the above tips, so I'll post that when I'm done.
评论 #2506348 未加载
jordanmessinaabout 14 years ago
Really great writeup! You should check out Bueda's django-boilerplate repo on Github. Particularly their environment.py file which resolves your dislike for putting site specific apps in the root (it adds them all to the path instead): <a href="https://github.com/bueda/django-boilerplate" rel="nofollow">https://github.com/bueda/django-boilerplate</a>
eliabout 14 years ago
Nice post. I like that it explains <i>why</i> you like this layout.<p>I'm working on my first real Django project now and as a newbie I found the lack of a clear consensus on how to structure the files a bit of a challenge.
jamespacileoabout 14 years ago
Great article. Might use a few ideas in <a href="http://www.djangocanvas.com" rel="nofollow">http://www.djangocanvas.com</a>, I sitll haven't finalized the project structure and will likely support multiple ones.
评论 #2508935 未加载
yuvadamabout 14 years ago
Great stuff!<p>I personally have been using many of these techniques in Django projects of mine, but it's nice to have a repo with everything in the same place.<p>Specifically - I love the lambda * x hack.