The PEAK Developers' Center   Diff for "WikiUp" UserPreferences
 
HelpContents Search Diffs Info Edit Subscribe XML Print View
Ignore changes in the amount of whitespace

Differences between version dated 2008-04-28 19:40:53 and 2010-08-11 19:36:50 (spanning 6 versions)

Deletions are marked like this.
Additions are marked like this.

Updating Project Wiki Pages from Docs using WikiUp
==================================================
 
NEW in 1.1:
    The ``--changed-file`` or ``-f`` option now lets you specify a single
    file to upload. (See `Command-Line Usage`_ below for details.)
 
The WikiUp project defines a setuptools extension to allow uploading Wiki
pages from source documentation. It's primarily intended to be useful for
PEAK projects to update the PEAK Wiki, but other projects could make use of

In other words, a file with a section for each wiki, and a pagename + filename
on each line. (The filename is actually optional; if you just list a pagename
without an ``=``, the filename will be assumed to be the same as the page
name.)
name.) Filenames must be relative to the setup directory, and use ``/`` as
a separator, as they will be converted to an OS path using the distutils
``convert_path()`` function.
 
To configure a Wiki, you need to add it to a distutils config file (usually
your ``pydistutils.cfg`` or ``~/.pydistutils.cfg``) like so::
your ``$HOME/pydistutils.cfg`` or ``~/.pydistutils.cfg`` file) like so::
 
    [wikiup-wikiname]
    url = base url here

given ``--config-file`` or ``-C`` to specify an alternate config file in place
of the local ``wikiup.cfg`` file.
 
Also, if you have many wiki pages, you can specify just a single filename to
update, using ``--changed-file`` or ``-f``. The file will be uploaded to all
the matching pages in the project's ``wikiup.cfg``. (Note: this option is
case-sensitive and must exactly match one or more filenames in ``wikiup.cfg``,
or nothing will be uploaded.)
 
 
The ``OldMoin`` Plugin
----------------------

section, in addition to the required ``type`` and ``url``::
 
    [wikiup-foo]
 
    type = OldMoin
    url = something
    uid = login.id.here
 
    uid = login.id.goes.here
    page_format = {{{ %s }}}
 
The ``uid`` allows you to specify a MoinMoin login ID to use; if specified,
the plugin will use the ``userform`` action to log in before uploading any
the plugin will use the ``userform`` Wiki action to log in as that ID before
uploading any pages.
 
The ``page_format`` is a format string (defaulting to ``"#format rst\n%s"``)
that will be used to convert the raw upload file into the page text that will
be posted to the wiki. The string is interpreted using the ``string_escape``
codec, so you will need to double-up on backslashes to keep them from being
treated as character escapes.
 
 
Adding Plugins

PythonPowered
ShowText of this page
EditText of this page
FindPage by browsing, title search , text search or an index
Or try one of these actions: AttachFile, DeletePage, LikePages, LocalSiteMap, SpellCheck