Changeset 4554

Show
Ignore:
Timestamp:
05/01/08 12:12:43 (3 months ago)
Author:
mramm
Message:

Removing old index, updating DownloadInstall? to match updates in the wiki.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/docs/2.0/DownloadInstall.rst

    r4370 r4554  
    1  
    2  
    3  
    4 How to install TurboGears 2 
     1How to install TurboGears 2  
    52============================= 
    63 
     
    96We do expect to have a technology preview release sometime soon, and that should provide a clear picture of the TurboGears 2 stack, and a slightly more stable API.   However, if you want API stability and good documentation, you may want to consider building your application on TurboGears 1 and porting it to TG2 after it is officially released. 
    107 
     8Installing Pylons: 
     9----------------------- 
     10 
     11You could easy_install pylons with command:: 
     12 
     13 $ easy_install -f http://pylonshq.com/download/0.9.7 -U Pylons 
     14 
    1115Installing Pylons from Source: 
    12 ------------------------------ 
     16-------------------------------- 
    1317 
    14 Pylons uses the Mercurial Version control system, so you probably need to install Mercurial before you can pull down the latest development source for Pylons. Mercurial `packages are available <http://www.selenic.com/mercurial/wiki/index.cgi/BinaryPackages>`_ for Windows, Mac OSX, and other OS's. 
     18.. note:: If you've installed pylons in previous section, you could skip to next section. 
     19 
     20Pylons uses the Mercurial Version control system, so if you want to install from repository,  you probably need to install Mercurial before you can pull down the latest development source for Pylons. Mercurial `packages are available <http://www.selenic.com/mercurial/wiki/index.cgi/BinaryPackages>`_ for Windows, Mac OSX, and other OS's. 
    1521 
    1622First you need to install: 
     
    2430 $ hg clone http://pylonshq.com/hg/pylons-dev Pylons 
    2531 
     32 
    2633To tell setuptools to use the version you are editing in the Pylons directory:: 
    2734 
    28  $ cd Pylons  
    29  $ python setup.py develop 
     35  $ cd Pylons   
     36  $ python setup.py develop 
     37 
    3038 
    3139**Mac OSX Leopard** comes with Python 2.5 but does not include **setuptools**. Install it using the instructions above. 
    3240 
    33 **Cygwin** does not include the necessary binary file **sqlite3.dll**; if you want to run cygwin you'll need 
    34 to install a different database. If you have cygwin installed and you want to use the default setup described 
    35 here, you must perform all operations, including setup operations, within DOS command windows, not cygwin command windows. 
     41**Cygwin** does not include the necessary binary file **sqlite3.dll**; if you want to run cygwin you'll need to install a different database. If you have cygwin installed and you want to use the default setup described here, you must perform all operations, including setup operations, within DOS command windows, not cygwin command windows. 
    3642 
    3743Now you can make changes to the files in the Pylons directory and the code will run exactly as if you had installed a version of the egg with the changes you have made. 
    3844 
    3945Installing TurboGears 2 from Source: 
    40 ------------------------------------ 
     46-------------------------------------- 
     47 
     48TurboGears 2 are constructed by a bunch of packages. 
    4149 
    4250Check out the latest code from subversion:: 
    4351 
    4452 $ cd .. 
    45  $ svn co http://svn.turbogears.org/trunk tg2 
     53 $ svn co http://svn.turbogears.org/projects/tg.devtools/trunk tgdev  
     54 $ svn co http://svn.turbogears.org/trunk tg2  
     55 $ svn co http://svn.turbogears.org/projects/tgrepozewho/trunk tgrepozewho 
    4656 
    47 Then you repeat the same steps to tell setuptools/python to use the new tg2 installation:: 
     57tg2 package is TurboGears 2 core. Others are paster command plugins to create default template, admin interface, and migrations. 
    4858 
    49  $ cd tg2  
     59Then you repeat the same steps to tell setuptools/python to use the new tg2 installation. 
     60 
     61Install tgrepozewho:: 
     62 
     63 $ cd tgrepozewho  
    5064 $ python setup.py develop 
    5165 
    52 Then you have installed TurboGears 2.  
     66Install TurboGears 2 server:: 
     67 
     68 $ cd ..  
     69 $ cd tg2   
     70 $ python setup.py develop 
     71 
     72Install TurboGears 2 developer tools:: 
     73 
     74 $ cd ..  
     75 $ cd tgdev  
     76 $ python setup.py develop 
     77 
     78Then you have installed TurboGears 2. 
     79 
     80 .. note:: if you have installed old dependency packages, you could remove them from:: 
     81 
     82 {python_path}/site-packages/easy_install.pth 
     83 
    5384 
    5485Validate the installation: 
    55 ------------------------------------ 
     86---------------------------- 
    5687 
    5788To check if you installed TurboGears 2 correctly, type:: 
    5889 
    59   paster --help 
     90 $ paster --help 
    6091 
    6192and you'll see a new "TurboGears2" command section in paster help. 
     
    6394Paster has replaced the old tg-admin command, and most of the tg-admin commands have now been reimplemented as paster commands. For example, "tg-admin quickstart" command has changed to "paster quickstart" command, and "tg-admin info" command has changed to "paster tginfo" command. 
    6495 
    65 Be sure to check out our `What's new in TurboGears 2.0 <RoughDocs/WhatsNew>`_ page to get a picture of what's changed in TurboGears2 so far. 
     96Be sure to check out our `What's new in TurboGears 2.0 <2.0/RoughDocs/WhatsNew>`_ page to get a picture of what's changed in TurboGears2 so far. 
    6697 
    6798Troubleshooting 
    68 --------------- 
     99---------------- 
    69100 
    70101If you get an error about ``ObjectDispatchController`` this means your Pylons installation is out-of-date. Make sure it's fresh ("hg pull -u" or "hg pull" followed by hg update -- alternatively you can create a brand new Pylons branch in a new directory with "hg clone"). 
     
    72103When installing on Mac OSX, if you get an error mentioning "No local packages or download links found for RuleDispatch", you can try the solution posted to the `ToscaWidgets discussion list <http://groups.google.com/group/toscawidgets-discuss/browse_thread/thread/cb6778810e96585d>`_, which advises downloading it directly:: 
    73104 
    74   $ sudo easy_install -U -f http://toscawidgets.org/download/wo_speedups/ RuleDispatch  
    75  
    76  
     105 . $ sudo easy_install -U -f http://toscawidgets.org/download/wo_speedups/ RuleDispatch 
    77106If you get the following error when starting a project with ``paster serve``:: 
    78107 
    79    AttributeError: 'WSGIRequest' object has no attribute 'accept_language' 
    80  
     108 . AttributeError: 'WSGIRequest' object has no attribute 'accept_language' 
    81109update your Pylons checkout with ``hg update`` and try again. 
    82110 
    83111If ``python setup.py develop`` gives you:: 
    84112 
    85   Traceback (most recent call last): 
    86     File "setup.py", line 3, in <module> 
    87       from ez_setup import use_setuptools 
     113 . Traceback (most recent call last): 
     114  . File "setup.py", line 3, in <module> 
     115   . from ez_setup import use_setuptools 
     116 
    88117 
    89118... commenting out the first two lines in setup.py seems to work.  See `this discussion <http://groups.google.com/group/pylons-discuss/browse_thread/thread/1ccf9366004c8e11>`_ 
     119 
     120It is possible you might see a few other error messages.  Here are the correct way to fix the dependency problems so things will install properly. 
     121 
     122If you get this error about PyProtocols:: 
     123 
     124   error: Could not find suitable distribution for Requirement.parse('PyProtocols>=1.0a0dev-r2302') 
     125 
     126Then do this:: 
     127 
     128  $ wget http://dbsprockets.googlecode.com/files/PyProtocols-1.0a0dev-r2302.zip 
     129  $ unzip PyProtocols-1.0a0dev-r2302.zip 
     130  $ cd PyProtocols-1.0a0dev-r2302 
     131  $ python setup.py develop 
     132 
     133 
     134If you get this error about RuleDispatch:: 
     135 
     136  error: Could not find suitable distribution for Requirement.parse('RuleDispatch>=0.5a0.dev-r2306') 
     137 
     138Then you need to do the following:: 
     139 
     140  $ cd .. 
     141  $ wget http://dbsprockets.googlecode.com/files/RuleDispatch-0.5a0.dev-r2306.tar.gz 
     142  $ tar xzf RuleDispatch-0.5a0.dev-r2306.tar.gz 
     143  $ cd RuleDispatch-0.5a0.dev-r2306 
     144  $ python setup.py develop 
     145