rpms/python-HTMLgen/devel debian_2.2.2-11.patch, NONE, 1.1 python-HTMLgen.spec, 1.12, 1.13
José Abílio Oliveira Matos (jamatos)
fedora-extras-commits at redhat.com
Tue Aug 28 15:49:19 UTC 2007
- Previous message (by thread): rpms/gnupg2/F-7 .cvsignore, 1.23, 1.24 gnupg2.spec, 1.72, 1.73 sources, 1.25, 1.26 gnupg-2.0.5-no_close.patch, 1.1, NONE
- Next message (by thread): rpms/kernel/devel kernel.spec,1.125,1.126
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: jamatos
Update of /cvs/pkgs/rpms/python-HTMLgen/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv7821
Modified Files:
python-HTMLgen.spec
Added Files:
debian_2.2.2-11.patch
Log Message:
* Tue Aug 28 2007 José Matos <jamatos[AT]fc.up.pt> - 2.2.2-10
- Added comment regarding homepage availability.
- Apply debian's patches.
- Include documentation.
debian_2.2.2-11.patch:
--- NEW FILE debian_2.2.2-11.patch ---
--- htmlgen-2.2.2.orig/HTMLgen.py
+++ htmlgen-2.2.2/HTMLgen.py
@@ -284,7 +284,7 @@
if self.meta: s.append(str(self.meta))
if self.base: s.append(str(self.base))
if self.stylesheet:
- s.append('\n <LINK rel=stylesheet href="%s" type=text/css title="%s">\n' \
+ s.append('\n <LINK rel=stylesheet href="%s" type="text/css" title="%s">\n' \
% (self.stylesheet, self.stylesheet))
if self.style:
s.append('\n<STYLE>\n<!--\n%s\n-->\n</style>\n' % self.style)
@@ -1083,7 +1083,7 @@
Overloaded by child classes to represent other list styles.
"""
- return '%s<LI>%s\n' % (self.pad*self.lvl, item)
+ return '%s<LI>%s</LI>\n' % (self.pad*self.lvl, item)
def start_element(self):
"""Generic creator for the HTML element opening tag.
@@ -2463,7 +2463,7 @@
import urlparse
self.unparse = urlparse.urlunparse
self.proto, self.node, self.path, self.params, self.query, self.fragment = \
- urlparse(url)
+ urlparse.urlparse(url)
self.dir, self.file = self.split(self.path)
def split(self, p):
--- htmlgen-2.2.2.orig/HTMLutil.py
+++ htmlgen-2.2.2/HTMLutil.py
@@ -1,4 +1,3 @@
-#!/usr/bin/env python
"""This module provides utility functions/classes associated with HTMLgen.
This is functionality use by HTMLgen script writers rather than by HTMLgen
@@ -19,7 +18,7 @@
# OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
__version__ = '$Id: HTMLutil.py,v 1.3 1998/05/28 20:14:52 friedric Exp $'
-import string, regex, os
+import string, re, os
import HTMLgen, HTMLcolors
from types import *
@@ -79,7 +78,7 @@
"""Determine if the text have been marked by a previous gsub.
(ugly hack but it works)
"""
- if regex.search('\(</?FONT\)\|\(</?STRONG\)', text) > -1:
+ if re.search('\(</?FONT\)\|\(</?STRONG\)', text) > -1:
return 1
else:
return 0
@@ -125,13 +124,13 @@
not_backslash = "[^\\\\]"
triple_single = "'''"
triple_double = '"""'
-_doc_start_re = regex.compile(
+_doc_start_re = re.compile(
"\(^\|" + not_backslash + "\)" # bol or not backslash
+ "\(" + triple_single + "\|" + triple_double + "\)" )
single_re = not_backslash + triple_single
double_re = not_backslash + triple_double
-_triple_re = { triple_single : regex.compile(single_re),
- triple_double : regex.compile(double_re) }
+_triple_re = { triple_single : re.compile(single_re),
+ triple_double : re.compile(double_re) }
del not_backslash, triple_single, triple_double, \
single_re, double_re
@@ -150,13 +149,13 @@
return (None, None)
return startquote, quotefinder.regs[0][1]
-string_re = regex.compile('\(\(\'[^\'\n]*\'\)\|\("[^"\n]"\)\)')
+string_re = re.compile('\(\(\'[^\'\n]*\'\)\|\("[^"\n]"\)\)')
def find_string_literal( s, begin=0 ):
if string_re.search(s, begin) > -1:
return string_re.regs[1]
return (None, None)
-comment_re = regex.compile('#.*$')
+comment_re = re.compile('#.*$')
def find_comment( s, begin=0 ):
while comment_re.search(s, begin) > -1:
if been_marked(comment_re.group(0)):
@@ -166,13 +165,13 @@
return (None, None)
Name = '[a-zA-Z_][a-zA-Z0-9_]*'
-func_re = regex.compile('\(^[ \t]*def[ \t]+' +Name+ '\)[ \t]*(')
+func_re = re.compile('\(^[ \t]*def[ \t]+' +Name+ '\)[ \t]*(')
def find_function( s, begin=0 ):
if func_re.search(s, begin) > -1:
return func_re.regs[1]
return (None, None)
-class_re = regex.compile('\(^[ \t]*class[ \t]+' +Name+ '\)[ \t]*[(:]')
+class_re = re.compile('\(^[ \t]*class[ \t]+' +Name+ '\)[ \t]*[(:]')
def find_class( s, begin=0 ):
if class_re.search(s, begin) > -1:
return class_re.regs[1]
--- htmlgen-2.2.2.orig/HTMLcalendar.py
+++ htmlgen-2.2.2/HTMLcalendar.py
@@ -1,4 +1,3 @@
-#!/usr/bin/env python
# COPYRIGHT (C) 1997 ROBIN FRIEDRICH
# Permission to use, copy, modify, and distribute this software and its
# documentation for any purpose and without fee is hereby granted,
@@ -212,12 +211,12 @@
return value
else:
raise TypeError, ('cannot convert to int', value)
-import regex
-datepat = regex.compile('^ *\([0-9*][0-9]?\)[/-]' #first 2 char date field
+import re
+datepat = re.compile('^ *\([0-9*][0-9]?\)[/-]' #first 2 char date field
'\([0-9][0-9]?\)[/-]?' #second 2 char date field
'\([12][0-9][0-9][0-9]\)?[ \t]*:') #optional year field
-daypat = regex.compile('^ *\('+string.join(day_name,'\|')+'\)')
-timepat = regex.compile('\([0-9][0-9]?\):\([0-9][0-9]\)')
+daypat = re.compile('^ *\('+string.join(day_name,'\|')+'\)')
+timepat = re.compile('\([0-9][0-9]?\):\([0-9][0-9]\)')
def read_appt_file(filename):
"""Parsing function.
--- htmlgen-2.2.2.orig/barchart.py
+++ htmlgen-2.2.2/barchart.py
@@ -1,4 +1,3 @@
-#!/usr/bin/env python
"""Provides BarChart class which creates HTML 1D bar charts,
and StackedBarChart class to deal with multiple data plotting
--- htmlgen-2.2.2.orig/colorcube.py
+++ htmlgen-2.2.2/colorcube.py
@@ -1,4 +1,3 @@
-#!/usr/bin/env python
"""Utility to generate a table of browser safe colors.
"""
--- htmlgen-2.2.2.orig/NavLinks.py
+++ htmlgen-2.2.2/NavLinks.py
@@ -1,4 +1,3 @@
-#!/usr/bin/env python
#'$Id: NavLinks.py,v 1.1 1999/02/04 04:54:29 friedric Exp friedric $'
# COPYRIGHT (C) 1999 ROBIN FRIEDRICH email:Robin.Friedrich at pdq.net
# Permission to use, copy, modify, and distribute this software and
--- htmlgen-2.2.2.orig/Formtools.py
+++ htmlgen-2.2.2/Formtools.py
@@ -1,4 +1,3 @@
-#! /usr/bin/env python
"Provide some supporting classes to simplify Input Forms with HTMLgen"
#'$Id: Formtools.py,v 1.1 1999/04/19 23:45:36 friedric Exp friedric $'
# COPYRIGHT (C) 1999 ROBIN FRIEDRICH email: Robin.Friedrich at pdq.net
--- htmlgen-2.2.2.orig/ImagePaletteH.py
+++ htmlgen-2.2.2/ImagePaletteH.py
@@ -70,7 +70,7 @@
return ImagePalette(mode, palette * len(mode))
def random(mode = "RGB"):
- from whrandom import randint
+# from whrandom import randint
palette = map(lambda a: randint(0, 255), [0]*256*len(mode))
return ImagePalette(mode, palette)
--- htmlgen-2.2.2.orig/HTMLtest.py
+++ htmlgen-2.2.2/HTMLtest.py
@@ -1,8 +1,8 @@
-#!/bin/env python
+#!/usr/bin/env python
"""Test script which generates the online documentation for HTMLgen.
"""
-import string, regex, regsub, os, time, glob
+import string, re, os, time, glob
from HTMLcolors import *
from HTMLgen import *
import HTMLgen #only so I can pick off the __version__
@@ -232,11 +232,11 @@
doc.email = 'jefferson at montecello.virginia.gov'
doc.logo = ('../image/eagle21.gif', 64, 54)
# parse Declaration of Independence
- re_hline = regex.compile('^--+$')
- re_title = regex.compile('^Title:\(.*$\)')
+ re_hline = re.compile('^--+$')
+ re_title = re.compile('^Title:\(.*$\)')
font2 = Font(size='+2')
s = open(os.path.join(datadir, 'DoI.txt')).read()
- paragraphs = regsub.split(s, '\n\([\t ]*\n\)+')
+ paragraphs = re.split(s, '\n\([\t ]*\n\)+')
for para in paragraphs:
if not para: continue
if re_title.search(para) > -1:
@@ -263,7 +263,7 @@
#Ok parse that file
f = open(mpath(os.path.join(datadir, 'parrot.txt')))
line = f.readline()
- re_dialog = regex.compile('\(^[OC].*:\)\(.*\)')
+ re_dialog = re.compile('\(^[OC].*:\)\(.*\)')
while line:
if re_dialog.search(line) > -1:
role, prose = re_dialog.group(1,2)
Index: python-HTMLgen.spec
===================================================================
RCS file: /cvs/pkgs/rpms/python-HTMLgen/devel/python-HTMLgen.spec,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- python-HTMLgen.spec 12 Dec 2006 00:09:09 -0000 1.12
+++ python-HTMLgen.spec 28 Aug 2007 15:48:47 -0000 1.13
@@ -3,13 +3,16 @@
Name: python-HTMLgen
Version: 2.2.2
-Release: 9%{?dist}
+Release: 10%{?dist}
Summary: A class library for the generation of HTML documents
Group: Development/Libraries
License: MIT
+# For the moment these page have not yet been restored. (jamatos-20070828)
URL: http://starship.python.net/lib.html
-Source0: http://starship.python.net/crew/friedrich/HTMLgen.tar.gz
+Source: http://starship.python.net/crew/friedrich/HTMLgen.tar.gz
+# Apply debian's patch (with all the debian strict parts stripped).
+Patch: debian_2.2.2-11.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: python-devel
@@ -22,13 +25,19 @@
%prep
%setup -q -n HTMLgen
+%patch -p1
%build
%install
rm -rf $RPM_BUILD_ROOT
install -d -m 0755 $RPM_BUILD_ROOT%{python_sitelib}
-for file in HTMLgen.py HTMLcolors.py HTMLutil.py HTMLcalendar.py barchart.py colorcube.py imgsize.py NavLinks.py Formtools.py ImageH.py ImageFileH.py ImagePaletteH.py GifImagePluginH.py JpegImagePluginH.py PngImagePluginH.py; do
+
+for file in HTMLgen.py HTMLcolors.py HTMLutil.py HTMLcalendar.py \
+ barchart.py colorcube.py imgsize.py NavLinks.py Formtools.py ImageH.py \
+ ImageFileH.py ImagePaletteH.py GifImagePluginH.py JpegImagePluginH.py \
+ PngImagePluginH.py
+do
install -m 0644 $file $RPM_BUILD_ROOT%{python_sitelib}
done
%{__python} %{pydir}/compileall.py $RPM_BUILD_ROOT%{python_sitelib}
@@ -39,10 +48,16 @@
%files
%defattr(-,root,root,-)
+%doc README html image data
%{python_sitelib}/*.py
%{python_sitelib}/*.py[co]
%changelog
+* Tue Aug 28 2007 José Matos <jamatos[AT]fc.up.pt> - 2.2.2-10
+- Added comment regarding homepage availability.
+- Apply debian's patches.
+- Include documentation.
+
* Tue Dec 12 2006 José Matos <jamatos[AT]fc.up.pt> - 2.2.2-9
- Rebuild for python 2.5.
- Previous message (by thread): rpms/gnupg2/F-7 .cvsignore, 1.23, 1.24 gnupg2.spec, 1.72, 1.73 sources, 1.25, 1.26 gnupg-2.0.5-no_close.patch, 1.1, NONE
- Next message (by thread): rpms/kernel/devel kernel.spec,1.125,1.126
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list