← Back to team overview

widelands-dev team mailing list archive

[Merge] lp:~widelands-dev/widelands-website/adjusted_README into lp:widelands-website

 

kaputtnik has proposed merging lp:~widelands-dev/widelands-website/adjusted_README into lp:widelands-website.

Commit message:
Adjusted README:

- Added making "widelands developer documentation"
- Added Paragraph for python version


Requested reviews:
  Widelands Developers (widelands-dev)

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands-website/adjusted_README/+merge/304860

Adjusted README:

- Added making "widelands developer documentation"
- Added Paragraph for python version

Please proofread :-)
-- 
Your team Widelands Developers is requested to review the proposed merge of lp:~widelands-dev/widelands-website/adjusted_README into lp:widelands-website.
=== modified file 'README.txt'
--- README.txt	2016-06-28 18:10:42 +0000
+++ README.txt	2016-09-04 09:47:44 +0000
@@ -13,17 +13,25 @@
 
    $ sudo apt-get install python-dev python-virtualenv python-pip mercurial bzr subversion git-core sqlite3
    $ sudo apt-get build-dep python-numpy
+
+Used python version
+-------------------
+
+Currently the website depends on python 2.7. In case you have python 3 as default (like on arch-linux),
+you have to adjust the python relevant commands to use python 2.7. F.e. 'virtualenv2 wlwebsite' creates
+a virtualenvironment using python 2.7. If the virtualenvironment is activated, python 2.7 will be become
+standard for executing python code in this shell.
    
 Setting up the local environment
 --------------------------------
 
-Go to the directory you want to install the homepage to, then run::
+Go to the directory you want to install the homepage to, then run:
 
    $ export PYTHONPATH=
 
 This will make sure that your virtual environment is not tainted with python
 packages from your global site packages. Very important!
-Now, we create and activate our environment. This installation depends on python2.7, so you must may use a special virtualenv-command: 
+Now, we create and activate our environment:
 
    $ virtualenv wlwebsite
    $ cd wlwebsite
@@ -85,10 +93,11 @@
 ^^^^^^^^^^^^^^^^^^^^^^^
 
 Go to http://localhost:8000/admin. Log in with your super user and go to the
-following Tables:
+following tables:
 
 - Site/Sites: Change your site name from example.com to localhost:8000. 
 - Wlprofile/Profiles: Add yourself as a user
+- Wlggz/Ggz: Add yourself as a user
 
 Now everything should work.
 
@@ -121,6 +130,34 @@
 
    $ ./manage.py update_help_pdf
 
+Setting up widelands source code documentation
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+You will need the widelands source code for this, see
+
+https://wl.widelands.org/wiki/BzrPrimer/
+
+Change to the directory doc/sphinx/ of the source code and run
+
+   $ ./extract_rst.py
+
+Now create the documentation as json files. You have to provide the path to
+the sphinx-build executable of the website:
+
+   $ ~/wlwebsite/bin/sphinx-build -b json -d build/doctrees source build/json
+
+A new directory containing json files is created in doc/sphinx/build/json. The full path
+to this directory has to be set in the sphinxdoc-app of the website:
+
+Open http://localhost:8000/admin/sphinxdoc/app/ and add a new app with this values:
+
+Name: Widelands developer documentation
+Slug: wl
+Path: /your/path/to/widelands-src/doc/sphinx/build/json/
+
+Open http://localhost:8000/docs/wl/ to see if all is working.
+
+
 Contact
 =======
 


Follow ups