From 5e80545ea70d7304b62333042356484d29fbad1f Mon Sep 17 00:00:00 2001 From: =?utf8?q?G=C3=BCnter=20Milde?= Date: Wed, 12 Oct 2011 22:22:34 +0200 Subject: [PATCH] More adaptions github (still incomplete) --- README.rst | 52 +++++++++++++++++ doc/.templates/layout.html | 8 +-- doc/Makefile | 8 ++- doc/download/index.txt | 22 ++++---- doc/index.txt | 43 ++++---------- doc/pylit.css | 137 --------------------------------------------- pylit.py | 4 +- 7 files changed, 85 insertions(+), 189 deletions(-) create mode 100644 README.rst delete mode 100644 doc/pylit.css diff --git a/README.rst b/README.rst new file mode 100644 index 0000000..0c55deb --- /dev/null +++ b/README.rst @@ -0,0 +1,52 @@ +PyLit +***** + +`Literate Programming`_ with reStructuredText_ + +.. epigraph:: + + The idea is that you do not document programs (after the fact), but + write documents that *contain* the programs. + + -- John Max Skaller + +What is it + PyLit (Python Literate) provides a plain but efficient tool for + literate programming: a `bidirectional text/code converter`. + +Install + As `PyLit` is a pure Python module, installation is straightforward: + Put `pylit.py`_ in Python's `Module Search Path`_. + +.. _pylit.py: http://github.com/gmilde/PyLit/raw/master/pylit.py + +Documentation + See http://pylit.berlios.de + + .. note:: The previous host of the PyLit project, berlios.de will close at + the end of 2011. For the transition period, some links might not work. + +Copyright + © 2005, 2009 Günter Milde. + +License + PyLit is `free software`_, released under the `GNU General Public License`_ + (GPL) version 2 or later. + + PyLit is distributed in the hope that it will be useful, but WITHOUT ANY + WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS + FOR A PARTICULAR PURPOSE. See the `GNU General Public License`_ for more + details. + + +.. References + +.. _Charming Python interview: + http://www.ibm.com/developerworks/library/l-pyth7.html +.. _bidirectional text/code converter: features.html#dual-source +.. _literate programming: literate-programming.html +.. _reStructuredText: http://docutils.sourceforge.net/rst.html +.. _module search path: + http://docs.python.org/tutorial/modules.html#the-module-search-path +.. _`free software`: http://www.gnu.org/philosophy/free-sw.html +.. _`GNU General Public License`: http://www.gnu.org/copyleft/gpl.html diff --git a/doc/.templates/layout.html b/doc/.templates/layout.html index 7631aaf..0767621 100644 --- a/doc/.templates/layout.html +++ b/doc/.templates/layout.html @@ -98,11 +98,7 @@ {% block footer %}

- Thanks to - - BerliOS - - for hosting this site. + +

{% endblock %} diff --git a/doc/Makefile b/doc/Makefile index d2596d8..a2ac977 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -5,7 +5,7 @@ SPHINXOPTS = -q SPHINXBUILD = sphinx-build -INDIR = rstdocs +INDIR = . HTMLDIR = build/html # Internal variables. @@ -13,6 +13,9 @@ ALLSPHINXOPTS = -d build/doctrees $(SPHINXOPTS) $(INDIR) .PHONY: help clean html web pickle htmlhelp latex changes linkcheck +logo/pylit-bold-framed.png: + inkscape --export-png=logo/pylit-bold-framed.png logo/pylit-bold-framed.svg + help: @echo "Please use \`make ' where is one of" @echo " html to make standalone HTML files" @@ -26,7 +29,8 @@ help: clean: -rm -rf build/* -html: +html: logo/pylit-bold-framed.png + echo $(INDIR) mkdir -p $(HTMLDIR) build/doctrees $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(HTMLDIR) @echo diff --git a/doc/download/index.txt b/doc/download/index.txt index 87c19de..fce496d 100644 --- a/doc/download/index.txt +++ b/doc/download/index.txt @@ -17,7 +17,7 @@ Download PyLit ----- `pylit.py`_ - There are no file releases yet. You get the most up to date version from + There are no file releases. You get the most up to date version from the `SVN repository`_. pylit_ @@ -26,6 +26,13 @@ pylit_ `pylit_test.py`_ unit tests for the `pylit` module +.. _`SVN repository`: + http://developer.berlios.de/svn/?group_id=7974 +.. _`pylit.py`: + http://svn.berlios.de/svnroot/repos/pylit/trunk/src/pylit.py +.. _pylit_test.py: + http://svn.berlios.de/svnroot/repos/pylit/trunk/test/pylit_test.py + Tools ----- @@ -37,13 +44,6 @@ Tools * `pylit functions`_ for the `JED editor`_ -.. _`SVN repository`: - http://developer.berlios.de/svn/?group_id=7974 -.. _`pylit.py`: - http://svn.berlios.de/svnroot/repos/pylit/trunk/src/pylit.py -.. _pylit_test.py: - http://svn.berlios.de/svnroot/repos/pylit/trunk/test/pylit_test.py - .. _Docutils: http://docutils.sourceforge.net/ .. _Sphinx: http://sphinx.pocoo.org/ .. _`Editor Support for reStructuredText`: @@ -67,8 +67,8 @@ As `PyLit` is a pure Python module, installation is straightforward: python -m pylit --help -* Easier invocation is possible with a small executable wrapper in the PATH. - On Unix you can use a script like pylit_: +* Easier invocation is possible with a small executable wrapper in the + binary PATH. On Unix you can use a script like pylit_: .. include:: pylit :literal: @@ -80,7 +80,7 @@ As `PyLit` is a pure Python module, installation is straightforward: .. _Python: http://www.python.org .. _module search path: - http://docs.python.org/tut/node8.html#SECTION008110000000000000000 + http://docs.python.org/tutorial/modules.html#the-module-search-path .. _pylit: pylit .. _command line use: ../usage/index.html#command-line-use .. _default settings: ../usage/index.html#defaults diff --git a/doc/index.txt b/doc/index.txt index 6963f34..5e3a200 100644 --- a/doc/index.txt +++ b/doc/index.txt @@ -10,6 +10,7 @@ PyLit The idea is that you do not document programs (after the fact), but write documents that *contain* the programs. [1]_ + Features -------- @@ -49,35 +50,20 @@ Download Project page ------------ -The PyLit project is hosted at `BerliOS`_. The `project page`_ -provides project statistics and info as well as links to the - -* Bugtracker_, -* `Feature Requests`_, -* pylit-users `Mail List`_, and -* the `SVN repository`_. - -.. _`project page`: http://developer.berlios.de/projects/pylit/ -.. _BerliOS: http://www.berlios.de -.. _Bugtracker: http://developer.berlios.de/bugs/?group_id=7974 -.. _`Feature requests`: http://developer.berlios.de/feature/?group_id=7974 -.. _`Mail List`: http://developer.berlios.de/mail/?group_id=7974 -.. _`SVN repository`: http://svn.berlios.de/wsvn/pylit - +The PyLit project is hosted at https://github.com/gmilde/PyLit. Changes ------- -PyLit `versions`_ and `SVN log`_. +PyLit `versions`_. Usage, behaviour, and API are not fixed yet. Ideas and feedback welcome. -The `PyLit source`_ has a chapter on `open questions`_ and ideas. +The `PyLit source`_ has a chapter on open questions and ideas. .. _versions: examples/pylit.py.html#changelog -.. _SVN log: http://svn.berlios.de/wsvn/pylit/?op=log -.. _PyLit source: examples/pylit.py.html +.. _PyLit source: raw/master/pylit.py .. _open questions: examples/pylit.py.html#open-questions Copyright @@ -88,14 +74,14 @@ Copyright License PyLit is `free software`_, released under the `GNU General Public License`_ - (GPL) + (GPL) version 2 or later. PyLit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the `GNU General Public License`_ for more details. -I am using PyLit in my daily work for more than two years now without major +I am using PyLit in my daily work for more than six years now without major problems. It works for me, but your mileage might vary. Remember to back up your data. A version control system is recommended. @@ -108,21 +94,16 @@ About this site --------------- The PyLit site is created from `reStructuredText`_ sources with Sphinx_. -(Earlier versions used the rest2web_ site builder.) - -It is located at http://pylit.berlios.de/ on `BerliOS`_, a free -(and ad-free!) service to Open Source developers by the Fraunhofer-Institut -für Offene Kommunikationssysteme (FOKUS) in Berlin. - -.. [1] John Max Skaller in a `Charming Python interview`_ +It is located at http://github.com/gmilde/PyLit on `github`_, a free +service to Open Source developers by `GitHub, Inc`. .. _reStructuredText: http://docutils.sourceforge.net/rst.html -.. _rest2web: http://www.voidspace.org.uk/python/rest2web/ .. _Sphinx: http://sphinx.pocoo.org/ +.. _github: http://github.com +.. References -.. _Python: http://www.python.org -.. _Docutils: http://docutils.sourceforge.net/ +.. [1] John Max Skaller in a `Charming Python interview`_ .. _Charming Python interview: http://www.ibm.com/developerworks/library/l-pyth7.html diff --git a/doc/pylit.css b/doc/pylit.css deleted file mode 100644 index 4d1c69e..0000000 --- a/doc/pylit.css +++ /dev/null @@ -1,137 +0,0 @@ -/* Stylesheet for the PyLit site (for use with rest2web) - -:Author: Guenter Milde -:Copyright: 2007 G. Milde - This stylesheet is released under the GPL v. 2 or later - -*/ - -@import url("html4css1.css"); /* docutils style sheet */ -/* @import url("pygments-default.css"); */ /* code syntax highlight */ - -/* r2w stylesheet variants and expamples */ - -/* @import url('pysrc.css'); */ /* Python code syntax highlight */ -/* @import url("voidspace_docutils2.css"); */ /* rounded boxes around headers */ -/* @import url("rest2web.css"); */ /* ditto */ -/* @import url("test.css"); */ /* greyish background */ -/* @import url("rest.css"); */ - -/* PyLit customizations */ -/* -------------------- */ - -div#Inhalt { - margin-left: 0em; - /* padding-left: 0.5em; */ - /* border: 1px dashed silver; */ - /* border-left-width: 1px */ - /* border-color: silver */ - min-width: 16em; /* Mindestbreite verhindert Anzeigefehler in modernen Browsern */ -} -h1.title { - text-align: left; - background-color: silver; - padding: 5px; -} -h1 { - font-size: 1.5em; - /* padding-left: 0.5em; */ -} -h2 { - font-size: 1.2em; -} -/* bold definition terms */ -dt { - font-weight: bold; -} - -/* background colour for literal blocks*/ -pre.literal-block, pre.doctest-block { - background-color: #FEFDD8; } -/* ... and inline literal */ -tt.docutils { - background-color: white; } - -/* last line with Berlios logo */ -p.thanks { - text-align: right; - background-color: silver; - } - -/* div.contents { margin: 5px } */ - -.logo { - vertical-align:middle; - background-color: white; - } - -/* Breadcrumps list as top bar: from the r2w standard functions doc */ -#crumbs { - background-color: #db8; - padding: 3px; - text-align: left; - /* font-size:15pt; */ - font-weight:bold; -} - -#crumbs .top-navigation { - margin: 0.5em; - color: black - background-color: silver - - -/* #crumbs li { */ -/* display:inline; */ -/* list-style:none; */ -/* margin:0; */ -/* padding:5px; */ -/* } */ -/* */ -/* #crumbs ul { */ -/* margin:0; */ -/* padding:0 */ -/* } */ - - -/* Navigation sidebar (currently not used) -(from http://de.selfhtml.org/css/layouts/mehrspaltige.htm ) */ - -ul#Navigation { - /* font-size: 0.8em; */ - float: left; width: 13em; - margin: 0; - padding: 0; - /* border: 1px dashed silver; */ - /* background-color: #eee; */ - background-color: #fee; -} -ul#Navigation li { - list-style: none; - margin: 0; - padding: 0.2em; - /* border: 1px grey; */ -} -ul#Navigation a { - display: block; - /* padding: 0.2em; */ - font-weight: bold; -} -ul#Navigation a:link { - color: black; -} -ul#Navigation a:visited { - color: #666; -} -ul#Navigation a:hover { - color: black; - background-color: #ffe; -} -ul#Navigation a:active { - color: white; - background-color: gray; -} -div.sidebar-links{ - margin-left: 0.5em -} - -img { border:none } diff --git a/pylit.py b/pylit.py index 2081992..d2885eb 100755 --- a/pylit.py +++ b/pylit.py @@ -17,8 +17,8 @@ """pylit: bidirectional text <-> code converter -Covert between a *text source* with embedded computer code and a *code source* -with embedded documentation. +Convert between a *text document* with embedded code +and *source code* with embedded documentation. """ # .. contents:: -- 2.11.4.GIT