|
16 | 16 | # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, |
17 | 17 | # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. |
18 | 18 | # |
19 | | -# $Id: setup.py,v 1.25 2001-11-21 23:42:54 richard Exp $ |
| 19 | +# $Id: setup.py,v 1.26 2001-12-08 07:06:20 jhermann Exp $ |
20 | 20 |
|
21 | 21 | from distutils.core import setup, Extension |
22 | 22 | from distutils.util import get_platform |
|
29 | 29 | import test |
30 | 30 | test.go() |
31 | 31 |
|
32 | | -templates = 'classic', 'extended' |
33 | | -packagelist = [ 'roundup', 'roundup.backends', 'roundup.templates' ] |
34 | | -installdatafiles = [] |
35 | 32 |
|
36 | | -for t in templates: |
37 | | - makeHtmlBase(os.path.join('roundup', 'templates', t)) |
38 | | - packagelist.append('roundup.templates.%s'%t) |
39 | | - packagelist.append('roundup.templates.%s.detectors'%t) |
40 | | - tfiles = glob(os.path.join('roundup','templates', t, 'html', '*')) |
| 33 | +def isTemplateDir(dir): |
| 34 | + return dir[0] != '.' and dir != 'CVS' and os.path.isdir(dir) \ |
| 35 | + and os.path.isfile(os.path.join(dir, '__init__.py')) |
| 36 | + |
| 37 | +templates = map(os.path.basename, filter(isTemplateDir, |
| 38 | + glob(os.path.join('roundup', 'templates', '*')))) |
| 39 | +packagelist = [ |
| 40 | + 'roundup', |
| 41 | + 'roundup.backends', |
| 42 | + 'roundup.templates' |
| 43 | +] |
| 44 | +installdatafiles = [ |
| 45 | + ('share/roundup/cgi-bin', ['cgi-bin/roundup.cgi']), |
| 46 | +] |
| 47 | + |
| 48 | +for template in templates: |
| 49 | + tdir = os.path.join('roundup', 'templates', template) |
| 50 | + makeHtmlBase(tdir) |
| 51 | + |
| 52 | + # add the template package and subpackage |
| 53 | + packagelist.append('roundup.templates.%s' % template) |
| 54 | + packagelist.append('roundup.templates.%s.detectors' % template) |
| 55 | + |
| 56 | + # scan for data files |
| 57 | + tfiles = glob(os.path.join(tdir, 'html', '*')) |
41 | 58 | tfiles = filter(os.path.isfile, tfiles) |
| 59 | + installdatafiles.append( |
| 60 | + ('share/roundup/templates/%s/html' % template, tfiles) |
| 61 | + ) |
42 | 62 |
|
43 | 63 |
|
44 | | -setup ( name = "roundup", |
45 | | - version = "0.3.0", |
46 | | - description = "Roundup issue tracking system.", |
47 | | - author = "Richard Jones", |
48 | | - author_email = "[email protected]", |
49 | | - url = 'http://sourceforge.net/projects/roundup/', |
50 | | - packages = packagelist, |
51 | | - scripts = ['roundup-admin', 'roundup-mailgw', 'roundup-server'], |
52 | | - data_files= [ |
53 | | - ('share/roundup/cgi-bin', ['cgi-bin/roundup.cgi']), |
54 | | - ] |
| 64 | +setup( |
| 65 | + name = "roundup", |
| 66 | + version = "0.3.0", |
| 67 | + description = "Roundup issue tracking system.", |
| 68 | + author = "Richard Jones", |
| 69 | + author_email = "[email protected]", |
| 70 | + url = 'http://sourceforge.net/projects/roundup/', |
| 71 | + packages = packagelist, |
| 72 | + scripts = ['roundup-admin', 'roundup-mailgw', 'roundup-server'], |
| 73 | + data_files = installdatafiles |
55 | 74 | ) |
56 | 75 |
|
| 76 | + |
57 | 77 | # |
58 | 78 | # $Log: not supported by cvs2svn $ |
| 79 | +# Revision 1.25 2001/11/21 23:42:54 richard |
| 80 | +# Some version number and documentation fixes. |
| 81 | +# |
59 | 82 | # Revision 1.24 2001/11/06 22:32:15 jhermann |
60 | 83 | # Install roundup.cgi to share/roundup |
61 | 84 | # |
|
0 commit comments