Changeset 976


Ignore:
Timestamp:
Jun 25, 2012 4:34:17 PM (10 years ago)
Author:
mooney
Message:

Replaced old publish instructions in light of the new system.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • softGlue_examples/source/adding_examples.rst

    r923 r976  
    88
    99#. make a new subdirectory under ``source/``
    10 #. copy any image files into this new subdirectory
     10#. copy all documentation files into this new subdirectory
    1111#. copy ``programmable_pulse_train/index.rst``
    1212   into this new subdirectory
     
    2424   ``svn ci -m "new example"``
    2525
     26
     27.. note::  You must have the "sphinx-build" command (and possibly other related
     28        commands) in your path.  At APS, this command can be found in
     29        ``/APSshare/epd/<arch>/bin``. Also note that this is part of the Enthought
     30        Python distribution, so it doesn't work on solaris-sparc.
     31
    2632setting the subversion mime type of a file
    2733++++++++++++++++++++++++++++++++++++++++++
     
    3844++++++++++++++++++++++++++++++
    3945
    40 The subversion repository also can act as a WWW server.
    41 It is possible to publish the built HTML documentatiojn
    42 as a complete web site directly from the subversion server.
    43 For this to happen, the built documentation needs to be added
    44 to the subversion repository.  The MIME types of certain files
    45 needs to be set properly so the SVN server can deliver them
    46 identified in a way that WWW clients will render them properly.
    47 
    48 The commands below may be useful at times when adding
    49 new examples so the HTML files display properly from the
    50 subversion repository server::
    51 
    52         cd {softGlue_examples}
    53        
    54         # these commands will add all built HTML content
    55         svn add build/html/*
    56         svn add build/html/*/*
    57         # -or-  (to be more selective as to what is published)
    58         svn st -u
    59         svn add {any content from previous "svn st" command with "?" in left column}
    60        
    61         # Now, you need to set the MIME types properly
    62         # or the SVN server will display the pages unformatted.
    63         svn ps svn:mime-type text/html build/html/*.html
    64         svn ps svn:mime-type text/html build/html/*/*.html
    65         svn ps svn:mime-type text/javascript build/html/_static/*.js
    66         svn ps svn:mime-type text/css build/html/_static/*.css
    67 
    68 Advisory about ``make clean``
    69 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    70 
    71 When a Sphinx web site is to be published from the SVN server,
    72 it is important to avoid the use of ``make clean``.  The *clean*
    73 procedure in the standard as-supplied Sphinx Makefile completely
    74 removes all content under the ``build/``
    75 subdirectory (including the ``build/html/.svn`` subdirectory)
    76 and removes the subversion information necessary to republish the WWW site.
    77 
    78 Instead of ``make clean``, you can force a complete Sphinx rebuild
    79 by removing the ``build/doctrees`` subdirectory.  Either edit
    80 the Makefile accordingly (as has been done here) or use this command::
    81 
    82    /bin/rm -rf build/doctrees
    83 
    84 On this modified Makefile, ``make clean`` should look like this::
    85 
    86   [jemian@gov,286,softGlue_examples]$ make clean
    87   #-rm -rf build/*
    88   rm -rf build/doctrees
    89 
    90 
    91 Restoring SVN ``build/html/.svn`` subdirectory
    92 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    93 
    94 If the ``build/html/.svn`` has been removed,
    95 it can be easy to restore from the SVN repository.
    96 Try these commands::
    97 
    98    mv build build.modified
    99    svn update
    100    make html
    101 
    102 Once you are confident that things work the way they should,
    103 you can remove the old ``build.modified`` directory::
    104 
    105    /bin/rm -rf build.modified
    106 
    107 .. note:: This can still retain unused content in the ``build/html``
    108    subdirectory (only a problem for the few who browse the
    109    ``build/html`` subdirectory contents). 
    110    To completely rebuild the published web site), it
    111    may be necessary to remove the ``build/html`` subdirectory from the
    112    SVN repository, commit that change, rebuild the web site, then add
    113    the new ``build/html`` subdirectory back into SVN.
     46#) % su svnbcext
     47#) % cd /home/joule/SVN/subversion/bcdaext/projects/softGlue_examples
     48#) % publish.sh
Note: See TracChangeset for help on using the changeset viewer.