From: Nick Fitzgerald Date: Thu, 8 Jul 2010 17:57:52 +0000 (-0700) Subject: Updating gh-pages to pycco X-Git-Url: http://git.khamidou.com/?a=commitdiff_plain;h=77d76f47601b37854e8e0b7687e33a34426acb57;p=pycco.git Updating gh-pages to pycco --- diff --git a/index.html b/index.html index 1f1e9d6..fcb6d69 100644 --- a/index.html +++ b/index.html @@ -2,7 +2,7 @@ - pocco + pycco @@ -12,7 +12,7 @@ - + @@ -32,19 +32,19 @@
#
-

Pocco is a Python port of Docco: +

Pycco is a Python port of Docco: the original quick-and-dirty, hundred-line-long, literate-programming-style documentation generator. It produces HTML that displays your comments alongside your code. Comments are passed through Markdown, and code is passed through Pygments syntax highlighting. This -page is the result of running Pocco against its own source file.

-

If you install Pocco, you can run it from the command-line:

-
pocco src/*.py
+page is the result of running Pycco against its own source file.

+

If you install Pycco, you can run it from the command-line:

+
pycco src/*.py
 

...will generate linked HTML documentation for the named source files, saving it into a docs folder.

-

To install Pocco, simply

+

To install Pycco, simply

sudo setup.py install
 
@@ -155,20 +155,20 @@ wherever our markers occur.

Once all of the code is finished highlighting, we can generate the HTML file and write out the documentation. Pass the completed sections into the template -found in resources/pocco.html

+found in resources/pycco.html

@@ -342,11 +343,11 @@ is lib/example.py, the HTML will be at docs/example.html # -

Create the template that we will use to generate the Pocco HTML page.

+

Create the template that we will use to generate the Pycco HTML page.

pocco

pycco

def generate_html(source, sections):
     title = path.basename(source)
     dest = destination(source)
-    html = pocco_template({
+    html = pycco_template({
         "title":       title,
         "sections":    sections,
         "sources":     sources,
         "path":        path,
         "destination": destination
     })
-    print "pocco = %s -> %s" % (source, dest)
+    print "pycco = %s -> %s" % (source, dest)
     fh = open(dest, "w")
     fh.write(html)
     fh.close()
@@ -205,9 +205,9 @@ found in resources/pocco.html

#
-

A list of the languages that Pocco supports, mapping the file extension to +

A list of the languages that Pycco supports, mapping the file extension to the name of the Pygments lexer and the symbol that indicates a comment. To -add another language to Pocco's repertoire, add it here.

+add another language to Pycco's repertoire, add it here.

languages = {
@@ -216,6 +216,7 @@ add another language to Pocco's repertoire, add it here.

".rb": { "name": "ruby", "symbol": "#" }, ".py": { "name": "python", "symbol": "#" }, ".scm": { "name": "scheme", "symbol": ";;" }, + ".lua": { "name": "lua", "symbol": "--" }, }
-
pocco_template = template(open(path.join(path.dirname(__file__),
-                                         "resources/pocco.html")).read())
+
pycco_template = template(open(path.join(path.dirname(__file__),
+                                         "resources/pycco.html")).read())
@@ -356,8 +357,8 @@ is lib/example.py, the HTML will be at docs/example.htmlThe CSS styles we"d like to apply to the documentation.

-
pocco_styles = open(path.join(path.dirname(__file__),
-                              "resources/pocco.css")).read()
+
pycco_styles = open(path.join(path.dirname(__file__),
+                              "resources/pycco.css")).read()
@@ -393,8 +394,8 @@ For each source file passed in as an argument, generate the documentation.

sources.sort() if sources: ensure_directory() - css = open("docs/pocco.css", "w") - css.write(pocco_styles) + css = open("docs/pycco.css", "w") + css.write(pycco_styles) css.close() def next_file(): diff --git a/pocco.css b/pycco.css similarity index 100% rename from pocco.css rename to pycco.css