|Version 12 (modified by 10 years ago) ( diff ),|
After installing Python:
As a Developer, it is best to run the Trunk version of Web2Py, so that you can fine-tune the version that you have installed & get involved with the Web2Py developer community:
git clone https://github.com/mdipierro/web2py.git
Note: HTTPS clones are not read-only (while git:// clones are). They will NOT work if your git is not configured as previously described.
There are occasional issues with the latest Trunk, so you may need to try a slightly older revision. If this is needed, after downloading:
cd web2py git log git checkout <hash>
"git log" shows you a log including the hash-value of every revesion. Checkout sets your working-copy to the revision with the specified hash-value.
For Instant Development
If you intend on developing the Sahana code base but do not intend on your changes making it back to the core (perhaps for a custom deployment) you can just clone the Trunk version of Eden:
cd web2py/applications git clone https://github.com/flavour/eden.git
Note the fact that we ensure that the name of the web2py application has no hyphen in, as otherwise it cannot run under Apache!
For Long Term Development
If you intend to develop for Sahana and have your code pulled into the core it is better to follow the GitHub Fork, Pull Request model, this is preferred over submitting patches. To do this:
- Create a free Git account
- Configure Git
- Fork Sahana
- Learn how to Pull Request your changes back into the core
For setting up a basic developer environment, with simpler security, it is necessary to edit a configuration file before starting Eden. Edit the web2py/application/eden/models/000_config.py. Look for the line with
FINISHED_EDITING_CONFIG_FILE = False and change False to True. Save the file.
To test your installation of Eden, without Eclipse, you can start web2py from the command line:
cd .. # the web2py main directory python web2py.py
If you want the Scheduler to run, then you'll need to start this separately: UserGuidelines/Scheduler
Once you have web2py running navigate to the server ( http://localhost:8000 by default ). From the web2py drop down menu navigate to "My Sites" and Select Eden. You should now be at the Eden homepage.
By default the 1st user to register will gain the Administrator role.
If you want a graphical debugger to set breakpoints & step through code then it is recommended to install Eclipse:
Now, see how to put your installation to work: