maven - Project management/build tools for a Django project? -


coming java development build , project management tools abound, i'd know what's available django. i'd use maven building things, there preferred way of doing it?

i'm looking following:

  • command-line building: mvn install easy , cool.
  • command-line test-runs. i'd integrate app hudson continuous integration, since i'm hardcore that.
  • deployment of media local test server (js, css, images, etc.)

is possible maven or tool? i'm embarking on pretty big project here , i'd have kicking-rad build/project management system maven project able grow on time.

two tools come mind both generic python tools - need not work django specifically:

  • fabric. use this; allows write remote commands if ssh'd in, upload code etc. these isn't can't , because bash script written in python, easy going. bash script written in python, means can import parts of django app, run tests or python can in process of running deployment.
  • buildout. i've not used this, our django frontent developer tells me absolutely tool use. @ guess, either same idea or more abstract, more python-orientated equivalent.

i sure there other packages available. best advice can give evaluate them briefly , pick 1 best fits scenario/team working style. note these deployment tools - builds in python don't make sense, since don't compile python code.

in terms of ci related stuff, there 3 commands django need know about:

  • ./manage.py test runs tests tests.py files. these django-specific enhancements unittest, python package.
  • ./manage.py collectstatic collects static files directory of choosing; highly useful pulling bits exist on static media server. have @ the static files howto how works.
  • you need south one, ./manage.py schemamigration app --auto && ./manage.py migrate app - applies model changes underlying sql schema. basically, if change model , don't use south, django upset because new field won't map old sql schema , won't able persist model. schema migrations, south supports, enable upgrade existing, populated database. worth doing hand before automating.
  • i should point out can write custom management commands execute ./manage.py whatever like. has fair amount of potential - i've used management commands command execute in cron job, example. build interactive commands admins of application and, of course, deployment , testing.

how these handled depends on setup have available , tools choose.

on compilation: closest building python freeze, a.k.a. py2exe or cxfreeze produce binaries. aware though these store python bytecode in exe , pass through interpreter, shared object anyway. also, can't cxfreeze django app, since django uses dynamic imports occur @ run time , cannot evaluated cxfreeze, compile time tool. discount building task needs doing. might see .pyc files appearing in directory - python converts python script python bytecode if changes have been made since last pyc. if no changes have been made, loads pyc file last time. python bytecode gets executed, isn't speedup in terms of performance, load time.


Comments

Popular posts from this blog

c# - How to set Z index when using WPF DrawingContext? -

razor - Is this a bug in WebMatrix PageData? -

visual c++ - Using relative values in array sorting ( asm ) -