keithsalisbury-subtrac 0.1.15 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/History.rdoc +3 -0
- data/{lib/subtrac/templates/projects/blank/svn/branches/README → README.rdoc} +0 -0
- data/bin/subtrac +1 -3
- data/lib/subtrac.rb +97 -292
- data/spec/subtrac_spec.rb +54 -0
- data/subtrac.gemspec +37 -0
- data/tasks/docs.rake +13 -0
- data/tasks/gemspec.rake +3 -0
- data/tasks/spec.rake +25 -0
- metadata +27 -45
- data/LICENSE +0 -20
- data/README.markdown +0 -200
- data/Rakefile +0 -56
- data/VERSION.yml +0 -4
- data/lib/subtrac/commands.rb +0 -6
- data/lib/subtrac/commands/create.rb +0 -13
- data/lib/subtrac/commands/install.rb +0 -10
- data/lib/subtrac/common/clients/index.wsgi +0 -89
- data/lib/subtrac/common/favicon.ico +0 -0
- data/lib/subtrac/common/images/trac/banner_bg.jpg +0 -0
- data/lib/subtrac/common/images/trac/bar_bg.gif +0 -0
- data/lib/subtrac/common/images/trac/footer_back.png +0 -0
- data/lib/subtrac/common/images/trac/main_bg.gif +0 -0
- data/lib/subtrac/common/images/trac/saint_logo_small.png +0 -0
- data/lib/subtrac/common/static/404.html +0 -14
- data/lib/subtrac/common/styles/trac.css +0 -222
- data/lib/subtrac/config/config.yml +0 -58
- data/lib/subtrac/passwords +0 -3
- data/lib/subtrac/shared/trac.ini +0 -178
- data/lib/subtrac/templates/location.erb +0 -16
- data/lib/subtrac/templates/projects/blank/svn/tags/README +0 -0
- data/lib/subtrac/templates/projects/blank/svn/trunk/README +0 -0
- data/lib/subtrac/templates/projects/blank/trac/wiki/WikiStart +0 -57
- data/lib/subtrac/templates/projects/new/svn/trunk/trac/wiki/WikiStart +0 -46
- data/lib/subtrac/templates/projects/new/trac/wiki/WikiStart +0 -23
- data/lib/subtrac/templates/projects/trac_theme/svn/trunk/index/index.html +0 -21
- data/lib/subtrac/templates/projects/trac_theme/svn/trunk/templates/layout.html +0 -56
- data/lib/subtrac/templates/projects/trac_theme/svn/trunk/templates/site.html +0 -27
- data/lib/subtrac/templates/projects/trac_theme/svn/trunk/templates/theme.html +0 -86
- data/lib/subtrac/templates/projects/trac_theme/trac/wiki/WikiStart +0 -4
- data/lib/subtrac/templates/trac.erb +0 -25
- data/lib/subtrac/templates/vhost.erb +0 -38
- data/lib/subtrac/version.rb +0 -4
data/Rakefile
DELETED
@@ -1,56 +0,0 @@
|
|
1
|
-
require 'rubygems'
|
2
|
-
require 'rake'
|
3
|
-
|
4
|
-
begin
|
5
|
-
require 'jeweler'
|
6
|
-
Jeweler::Tasks.new do |gem|
|
7
|
-
gem.name = "subtrac"
|
8
|
-
gem.summary = %Q{Simple and opinionated helper for creating and managing subversion and trac projects.}
|
9
|
-
gem.email = "keithsalisbury@gmail.com"
|
10
|
-
gem.homepage = "http://github.com/keithsalisbury/subtrac"
|
11
|
-
gem.authors = ["Keith Salisbury"]
|
12
|
-
gem.add_dependency('visionmedia-commander', '>= 3.2.5')
|
13
|
-
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
14
|
-
end
|
15
|
-
rescue LoadError
|
16
|
-
puts "Jeweler not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
|
17
|
-
end
|
18
|
-
|
19
|
-
require 'rake/testtask'
|
20
|
-
Rake::TestTask.new(:test) do |test|
|
21
|
-
test.libs << 'lib' << 'test'
|
22
|
-
test.pattern = 'test/**/*_test.rb'
|
23
|
-
test.verbose = true
|
24
|
-
end
|
25
|
-
|
26
|
-
begin
|
27
|
-
require 'rcov/rcovtask'
|
28
|
-
Rcov::RcovTask.new do |test|
|
29
|
-
test.libs << 'test'
|
30
|
-
test.pattern = 'test/**/*_test.rb'
|
31
|
-
test.verbose = true
|
32
|
-
end
|
33
|
-
rescue LoadError
|
34
|
-
task :rcov do
|
35
|
-
abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
|
36
|
-
end
|
37
|
-
end
|
38
|
-
|
39
|
-
|
40
|
-
task :default => :test
|
41
|
-
|
42
|
-
require 'rake/rdoctask'
|
43
|
-
Rake::RDocTask.new do |rdoc|
|
44
|
-
if File.exist?('VERSION.yml')
|
45
|
-
config = YAML.load(File.read('VERSION.yml'))
|
46
|
-
version = "#{config[:major]}.#{config[:minor]}.#{config[:patch]}"
|
47
|
-
else
|
48
|
-
version = ""
|
49
|
-
end
|
50
|
-
|
51
|
-
rdoc.rdoc_dir = 'rdoc'
|
52
|
-
rdoc.title = "subtrac #{version}"
|
53
|
-
rdoc.rdoc_files.include('README*')
|
54
|
-
rdoc.rdoc_files.include('lib/**/*.rb')
|
55
|
-
end
|
56
|
-
|
data/VERSION.yml
DELETED
data/lib/subtrac/commands.rb
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
module Subtrac
|
2
|
-
module Commands
|
3
|
-
class Create
|
4
|
-
def initialize(args, options)
|
5
|
-
options.project = ask("What is the name of the project you would like to create? ") if !options.project
|
6
|
-
options.client = ask("Which client is this project for? ") if !options.client
|
7
|
-
# this needs to load the updated configuration?
|
8
|
-
Subtrac.load_config()
|
9
|
-
Subtrac.create_project(options.project,options.client)
|
10
|
-
end
|
11
|
-
end
|
12
|
-
end
|
13
|
-
end
|
@@ -1,89 +0,0 @@
|
|
1
|
-
#!/usr/bin/env python
|
2
|
-
"""
|
3
|
-
A simple WSGI test application.
|
4
|
-
|
5
|
-
Its main purpose is to show that WSGI support works (meaning that the
|
6
|
-
web server and the WSGI adaptor / support module are configured correctly).
|
7
|
-
|
8
|
-
As a nice plus, it outputs some interesting system / WSGI values as a nice
|
9
|
-
HTML table.
|
10
|
-
|
11
|
-
The main use of this script will be using the WSGI "application" defined
|
12
|
-
below within your production WSGI environment. You will use some code similar
|
13
|
-
to what you see at the end of this script to use the application from that
|
14
|
-
environment. For the special case of apache2/mod_wsgi, it shoud be possible
|
15
|
-
to directly use this file.
|
16
|
-
|
17
|
-
If you start this script from the commandline either with python2.5 or with
|
18
|
-
and older python + wsgiref module installed, it will serve the content on
|
19
|
-
http://localhost:8000/ - this is mainly for debugging THIS script.
|
20
|
-
|
21
|
-
@copyright: 2008 by MoinMoin:ThomasWaldmann
|
22
|
-
@license: Python License, see LICENSE.Python for details.
|
23
|
-
"""
|
24
|
-
import os.path
|
25
|
-
import os
|
26
|
-
import sys
|
27
|
-
|
28
|
-
try:
|
29
|
-
__file__
|
30
|
-
except NameError:
|
31
|
-
__file__ = '?'
|
32
|
-
|
33
|
-
html_template = """\
|
34
|
-
<html>
|
35
|
-
<head>
|
36
|
-
<title>WSGI Test Script</title>
|
37
|
-
</head>
|
38
|
-
<body>
|
39
|
-
<h1>WSGI test script is working!</h1>
|
40
|
-
<table border=1>
|
41
|
-
<tr><th colspan=2>1. System Information</th></tr>
|
42
|
-
<tr><td>Python</td><td>%(python_version)s</td></tr>
|
43
|
-
<tr><td>Python Path</td><td>%(python_path)s</td></tr>
|
44
|
-
<tr><td>Platform</td><td>%(platform)s</td></tr>
|
45
|
-
<tr><td>Absolute path of this script</td><td>%(abs_path)s</td></tr>
|
46
|
-
<tr><td>Filename</td><td>%(filename)s</td></tr>
|
47
|
-
<tr><th colspan=2>2. WSGI Environment</th></tr>
|
48
|
-
%(wsgi_env)s
|
49
|
-
</table>
|
50
|
-
</body>
|
51
|
-
</html>
|
52
|
-
"""
|
53
|
-
|
54
|
-
row_template = " <tr><td>%s</td><td>%r</td></tr>"
|
55
|
-
|
56
|
-
|
57
|
-
def application(environ, start_response):
|
58
|
-
""" The WSGI test application """
|
59
|
-
# emit status / headers
|
60
|
-
status = "200 OK"
|
61
|
-
headers = [('Content-Type', 'text/html'), ]
|
62
|
-
start_response(status, headers)
|
63
|
-
|
64
|
-
# assemble and return content
|
65
|
-
content = html_template % {
|
66
|
-
'python_version': sys.version,
|
67
|
-
'platform': sys.platform,
|
68
|
-
'abs_path': os.path.abspath('.'),
|
69
|
-
'filename': __file__,
|
70
|
-
'python_path': repr(sys.path),
|
71
|
-
'wsgi_env': '\n'.join([row_template % item for item in environ.items()]),
|
72
|
-
}
|
73
|
-
return [content]
|
74
|
-
|
75
|
-
|
76
|
-
if __name__ == '__main__':
|
77
|
-
# this runs when script is started directly from commandline
|
78
|
-
try:
|
79
|
-
# create a simple WSGI server and run the application
|
80
|
-
from wsgiref import simple_server
|
81
|
-
print "Running test application - point your browser at http://localhost:8000/ ..."
|
82
|
-
httpd = simple_server.WSGIServer(('', 8000), simple_server.WSGIRequestHandler)
|
83
|
-
httpd.set_app(application)
|
84
|
-
httpd.serve_forever()
|
85
|
-
except ImportError:
|
86
|
-
# wsgiref not installed, just output html to stdout
|
87
|
-
for content in application({}, lambda status, headers: None):
|
88
|
-
print content
|
89
|
-
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -1,14 +0,0 @@
|
|
1
|
-
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
2
|
-
<html xmlns="http://www.w3.org/1999/xhtml">
|
3
|
-
<head>
|
4
|
-
<title>Ooops</title>
|
5
|
-
<link rel="stylesheet" type="text/css" href="trac.css" />
|
6
|
-
</head>
|
7
|
-
<body>
|
8
|
-
<p style="width: 600px;">
|
9
|
-
We couldn't find that, maybe you can try here: <a class="ext-link"
|
10
|
-
href="http://dev.saintdigital.co.uk"><span
|
11
|
-
class="icon">dev.saintdigital.co.uk</span></a>.
|
12
|
-
</p>
|
13
|
-
</body>
|
14
|
-
</html>
|
@@ -1,222 +0,0 @@
|
|
1
|
-
/* General */
|
2
|
-
body {
|
3
|
-
font: normal 13px Verdana,Arial,'Bitstream Vera Sans',Helvetica,sans-serif;
|
4
|
-
background: transparent;
|
5
|
-
margin: 0;
|
6
|
-
padding: 0;
|
7
|
-
}
|
8
|
-
a:link, a:visited {
|
9
|
-
color:#821;
|
10
|
-
}
|
11
|
-
object, embed {
|
12
|
-
display: block;
|
13
|
-
margin: 0 auto;
|
14
|
-
border-left: 1px solid #FFF;
|
15
|
-
border-right: 1px solid #FFF;
|
16
|
-
}
|
17
|
-
|
18
|
-
/* Header */
|
19
|
-
#banner {
|
20
|
-
margin: 10px 80px;
|
21
|
-
background-image: url(/images/trac/banner_bg.gif);
|
22
|
-
}
|
23
|
-
#metanav {
|
24
|
-
background: none;
|
25
|
-
color:#FFF;
|
26
|
-
display: block;
|
27
|
-
float: top;
|
28
|
-
padding: 0px;
|
29
|
-
height:27px
|
30
|
-
}
|
31
|
-
#mainnav {
|
32
|
-
border: 0;
|
33
|
-
padding: 0;
|
34
|
-
margin: 0;
|
35
|
-
background-image: url(/images/trac/bar_bg.gif);
|
36
|
-
height: 27px;
|
37
|
-
}
|
38
|
-
#mainnav ul {
|
39
|
-
font-size: 12px;
|
40
|
-
display: block;
|
41
|
-
margin: 0 80px;
|
42
|
-
padding: 0;
|
43
|
-
}
|
44
|
-
#mainnav ul li a:link, #mainnav ul li a:visited {
|
45
|
-
background: none;
|
46
|
-
color:#FFF;
|
47
|
-
display: block;
|
48
|
-
float: left;
|
49
|
-
padding: 0 25px;
|
50
|
-
line-height: 27px;
|
51
|
-
margin: 0;
|
52
|
-
border-left: 0;
|
53
|
-
border-right: 1px solid #FFF;
|
54
|
-
}
|
55
|
-
#mainnav ul .first a:link, #mainnav ul .first a:visited {
|
56
|
-
border-left: 1px solid #FFF;
|
57
|
-
}
|
58
|
-
#mainnav ul .active a:link, #mainnav ul .active a:visited {
|
59
|
-
border-right: 1px solid #FFF;
|
60
|
-
background: #DDD;
|
61
|
-
color:#000;
|
62
|
-
}
|
63
|
-
#mainnav.nav ul li a:hover, #mainnav.nav ul .active a:hover {
|
64
|
-
background: none;
|
65
|
-
border-right: 1px solid #FFF;
|
66
|
-
background-color: #EA2;
|
67
|
-
}
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
/* Main content */
|
74
|
-
#main {
|
75
|
-
background: url(/images/trac/main_bg.gif) top left repeat-x;
|
76
|
-
padding: 10px 80px;
|
77
|
-
}
|
78
|
-
#main .wikipage {
|
79
|
-
padding-left: 0;
|
80
|
-
}
|
81
|
-
.milestone .info h2 a em {
|
82
|
-
color: #F90;
|
83
|
-
}
|
84
|
-
.milestone .info .progress .closed {
|
85
|
-
background-color: #F90;
|
86
|
-
}
|
87
|
-
#content #ticket {
|
88
|
-
background-color: #FEC;
|
89
|
-
border: 1px solid #CCC;
|
90
|
-
}
|
91
|
-
#content #attachments, #content #changelog {
|
92
|
-
background-color: #EEE;
|
93
|
-
border: 1px solid #CCC;
|
94
|
-
}
|
95
|
-
#main .wikipage p {
|
96
|
-
margin: 15px 0;
|
97
|
-
}
|
98
|
-
#main .wikipage table {
|
99
|
-
margin: 15px 0 30px 0;
|
100
|
-
}
|
101
|
-
#main .wikipage hr {
|
102
|
-
margin: 30px 0;
|
103
|
-
height: 1px;
|
104
|
-
border: 0;
|
105
|
-
background-color: #CCC;
|
106
|
-
}
|
107
|
-
#main h1 {
|
108
|
-
margin: 20px 0 0 0;
|
109
|
-
font-size: 24px;
|
110
|
-
}
|
111
|
-
#main .wikipage h2 {
|
112
|
-
padding-top:30px;
|
113
|
-
border-top: 1px solid #CCC;
|
114
|
-
font-size: 18px;
|
115
|
-
margin: 30px 0 0 0;
|
116
|
-
}
|
117
|
-
#main .wikipage h3 {
|
118
|
-
font-size: 15px;
|
119
|
-
margin: 30px 0 0 0;
|
120
|
-
}
|
121
|
-
#main .wikipage ul {
|
122
|
-
margin-left: 0;
|
123
|
-
padding-left: 18px;
|
124
|
-
}
|
125
|
-
#main strong {
|
126
|
-
font-weight: bold;
|
127
|
-
}
|
128
|
-
#main i {
|
129
|
-
font-style: normal;
|
130
|
-
color: #7A2;
|
131
|
-
font-family: monospace;
|
132
|
-
}
|
133
|
-
#main dt {
|
134
|
-
margin-bottom: 5px;
|
135
|
-
font-weight: bold;
|
136
|
-
}
|
137
|
-
#main dl ul {
|
138
|
-
margin-top: 5px;
|
139
|
-
margin-bottom: 15px;
|
140
|
-
}
|
141
|
-
#main ul strong {
|
142
|
-
font-family: monospace;
|
143
|
-
}
|
144
|
-
#main .wikipage pre {
|
145
|
-
margin: 15px 0;
|
146
|
-
background-color: #000;
|
147
|
-
border: 1px solid #CCC;
|
148
|
-
color:#eee;
|
149
|
-
font-size: 12px;
|
150
|
-
padding: 10px;
|
151
|
-
}
|
152
|
-
#main .wikipage table {
|
153
|
-
width: 100%;
|
154
|
-
border-collapse: collapse;
|
155
|
-
border: 0;
|
156
|
-
}
|
157
|
-
#main .wikipage td {
|
158
|
-
padding: 5px;
|
159
|
-
font-size: 12px;
|
160
|
-
border-left: 0;
|
161
|
-
border-right: 0;
|
162
|
-
}
|
163
|
-
.wikipage .media {
|
164
|
-
background-color:#eee;
|
165
|
-
margin: 30px 0;
|
166
|
-
}
|
167
|
-
|
168
|
-
#main .wikipage img {
|
169
|
-
display: block;
|
170
|
-
margin: 15px auto 30px auto;
|
171
|
-
}
|
172
|
-
|
173
|
-
#main .wiki-toc {
|
174
|
-
background: #efefef;
|
175
|
-
border:0.1 dedede solid
|
176
|
-
|
177
|
-
}
|
178
|
-
|
179
|
-
|
180
|
-
/* Altlinks */
|
181
|
-
#altlinks {
|
182
|
-
text-align: left;
|
183
|
-
background-color:#eee;
|
184
|
-
padding: 10px 0 0 10px;
|
185
|
-
margin:20px 0 40px 0;
|
186
|
-
border-top: 1px solid #CCC;
|
187
|
-
border-bottom: 1px solid #CCC;
|
188
|
-
}
|
189
|
-
#altlinks h3 {
|
190
|
-
font-size: 15px;
|
191
|
-
}
|
192
|
-
#altlinks li {
|
193
|
-
padding: 0 10px 0 0;
|
194
|
-
}
|
195
|
-
#altlinks li a:link {
|
196
|
-
border-bottom: 1px dotted #58C;
|
197
|
-
color: #58C;
|
198
|
-
background: url(/images/trac/extlink.gif) 0 4px no-repeat;
|
199
|
-
padding-left: 20px;
|
200
|
-
}
|
201
|
-
#altlinks li a:hover {
|
202
|
-
border-bottom: 1px dotted #444;
|
203
|
-
color: #444;
|
204
|
-
background: url(/images/trac/extlink.gif) 0 4px no-repeat;
|
205
|
-
padding-left: 20px;
|
206
|
-
background-color: #EEE;
|
207
|
-
}
|
208
|
-
iframe {
|
209
|
-
border:0;
|
210
|
-
width: 100%;
|
211
|
-
height: 1200px;
|
212
|
-
padding: 0;
|
213
|
-
margin: 0;
|
214
|
-
}
|
215
|
-
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
/* Footer */
|
220
|
-
#footer {
|
221
|
-
display: none;
|
222
|
-
}
|
@@ -1,58 +0,0 @@
|
|
1
|
-
development: &non_production_settings
|
2
|
-
# Things that can be changed
|
3
|
-
:admin_user: "admin"
|
4
|
-
:server_name: "Subtrac Development Server"
|
5
|
-
:server_hostname: "dev.subtrac.com"
|
6
|
-
:server_ip: "192.168.2.1"
|
7
|
-
|
8
|
-
:installation_dir: test
|
9
|
-
|
10
|
-
:default_project_template: "blank"
|
11
|
-
:default_theme_template: "trac_theme"
|
12
|
-
:default_client: "Subtrac"
|
13
|
-
:default_project: "Public"
|
14
|
-
:shared_trac_ini: "shared/trac.ini"
|
15
|
-
|
16
|
-
:apache2_conf: /etc/apache2/sites-available
|
17
|
-
|
18
|
-
:ldap:
|
19
|
-
:enable: false
|
20
|
-
:host:
|
21
|
-
:port:
|
22
|
-
:basedn:
|
23
|
-
:user_rdn:
|
24
|
-
:group_rdn:
|
25
|
-
:store_bind:
|
26
|
-
:group_bind:
|
27
|
-
:bind_dn:
|
28
|
-
:bind_passwd:
|
29
|
-
|
30
|
-
:trac:
|
31
|
-
:permissions:
|
32
|
-
admins: TRAC_ADMIN
|
33
|
-
clients: WIKI_VIEW TICKET_CREATE TICKET_APPEND
|
34
|
-
developers: BROWSER_VIEW LOG_VIEW FILE_VIEW CHANGESET_VIEW TICKET_VIEW TICKET_CREATE TICKET_APPEND MILESTONE_VIEW MILESTONE_CREATE MILESTONE_MODIFY ROADMAP_VIEW REPORT_VIEW REPORT_SQL_VIEW`BROWSER_VIEW LOG_VIEW FILE_VIEW CHANGESET_VIEW TICKET_VIEW TICKET_CREATE TICKET_APPEND MILESTONE_VIEW MILESTONE_CREATE MILESTONE_MODIFY ROADMAP_VIEW REPORT_VIEW REPORT_SQL_VIEW
|
35
|
-
client: clients
|
36
|
-
|
37
|
-
# Internal config
|
38
|
-
:dirs:
|
39
|
-
:svn: svn
|
40
|
-
:trac: trac
|
41
|
-
:log: log
|
42
|
-
:docs: www
|
43
|
-
:conf: conf
|
44
|
-
:locations: locations
|
45
|
-
:temp: tmp
|
46
|
-
:urls:
|
47
|
-
:svn: "/svn"
|
48
|
-
:templates:
|
49
|
-
:virtual_host: "templates/vhost.erb"
|
50
|
-
:location: "templates/location.erb"
|
51
|
-
:trac: "templates/trac.erb"
|
52
|
-
:projects: "templates/projects"
|
53
|
-
|
54
|
-
test:
|
55
|
-
<<: *non_production_settings
|
56
|
-
|
57
|
-
production:
|
58
|
-
|