continuous4r 0.0.1 → 0.0.2
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.txt +1 -1
- data/Manifest.txt +34 -34
- data/PostInstall.txt +3 -0
- data/README.rdoc +58 -0
- data/Rakefile +28 -3
- data/lib/changelog_builder.rb +51 -0
- data/lib/continuous4r.rb +63 -426
- data/lib/dcov_builder.rb +144 -0
- data/lib/flay_builder.rb +38 -0
- data/lib/flog_builder.rb +120 -0
- data/lib/git_extractor.rb +48 -0
- data/lib/rcov_builder.rb +23 -0
- data/lib/rdoc_builder.rb +33 -0
- data/lib/reek_builder.rb +38 -0
- data/lib/roodi_builder.rb +41 -0
- data/lib/saikuro_builder.rb +20 -0
- data/lib/site/body-changelog.rhtml +1 -1
- data/lib/site/body-continuous4r-reports.rhtml +40 -47
- data/lib/site/body-dcov.rhtml +1 -21
- data/lib/site/body-flay.rhtml +16 -0
- data/lib/site/body-flog.rhtml +2 -10
- data/lib/site/body-rcov.rhtml +2 -3
- data/lib/site/body-rdoc.rhtml +1 -1
- data/lib/site/body-reek.rhtml +16 -0
- data/lib/site/body-roodi.rhtml +16 -0
- data/lib/site/body-saikuro.rhtml +32 -0
- data/lib/site/body-scm-usage.rhtml +13 -12
- data/lib/site/body-stats.rhtml +1 -1
- data/lib/site/body-tests.rhtml +1 -1
- data/lib/site/body-xdoclet.rhtml +29 -0
- data/lib/site/body-zentest.rhtml +1 -1
- data/lib/site/flog.html.erb +33 -0
- data/lib/site/flog_page.html.erb +74 -0
- data/lib/site/header.rhtml +36 -20
- data/lib/site/images/added.png +0 -0
- data/lib/site/images/deleted.png +0 -0
- data/lib/site/images/modified.png +0 -0
- data/lib/site/menu-continuous4r-reports.rhtml +4 -14
- data/lib/site/{menu-dcov.rhtml → menu-task.rhtml} +3 -5
- data/lib/site/style/maven-base.css +3 -0
- data/lib/site/syntax_highlighting.css +30 -0
- data/lib/stats_builder.rb +18 -0
- data/lib/subversion_extractor.rb +29 -19
- data/lib/tasks/continuous4r-project.xml +26 -0
- data/lib/tasks/continuous4r.rake +23 -0
- data/lib/tasks/continuous4r.rb +6 -0
- data/lib/tests_builder.rb +21 -0
- data/lib/tests_formatter.rb +13 -46
- data/lib/utils.rb +47 -0
- data/lib/xdoclet_builder.rb +48 -0
- data/lib/zen_test_formatter.rb +58 -28
- data/lib/zentest_builder.rb +19 -0
- data/script/console +10 -0
- data/script/console.cmd +1 -0
- data/script/destroy +1 -1
- data/script/generate +1 -1
- data/test/test_continuous4r.rb +1 -1
- data/test/test_helper.rb +1 -0
- data/website/index.html +141 -363
- data/website/index.txt +169 -228
- data/website/template.rhtml +2 -2
- metadata +66 -46
- data/License.txt +0 -20
- data/README.txt +0 -1
- data/config/hoe.rb +0 -71
- data/config/requirements.rb +0 -17
- data/lib/capistrano_formatter.rb +0 -19
- data/lib/continuous4r/version.rb +0 -9
- data/lib/flog_formatter.rb +0 -48
- data/lib/heckle_formatter.rb +0 -27
- data/lib/httperf_formatter.rb +0 -160
- data/lib/site/body-capistrano.rhtml +0 -8
- data/lib/site/body-heckle.rhtml +0 -16
- data/lib/site/body-httperf.rhtml +0 -8
- data/lib/site/body-kwala.rhtml +0 -35
- data/lib/site/body-railroad.rhtml +0 -29
- data/lib/site/menu-capistrano.rhtml +0 -23
- data/lib/site/menu-changelog.rhtml +0 -23
- data/lib/site/menu-flog.rhtml +0 -23
- data/lib/site/menu-heckle.rhtml +0 -23
- data/lib/site/menu-httperf.rhtml +0 -23
- data/lib/site/menu-kwala.rhtml +0 -23
- data/lib/site/menu-railroad.rhtml +0 -23
- data/lib/site/menu-rcov.rhtml +0 -23
- data/lib/site/menu-rdoc.rhtml +0 -23
- data/lib/site/menu-stats.rhtml +0 -23
- data/lib/site/menu-tests.rhtml +0 -23
- data/lib/site/menu-zentest.rhtml +0 -23
- data/log/debug.log +0 -0
- data/script/txt2html +0 -74
- data/script/txt2html.cmd +0 -1
- data/setup.rb +0 -1585
- data/tasks/deployment.rake +0 -34
- data/tasks/environment.rake +0 -7
- data/tasks/website.rake +0 -17
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
<h2>Flog Results</h2>
|
|
2
|
+
<p><a href='http://ruby.sadi.st/Flog.html'>Flog</a> measures code complexity.</p>
|
|
3
|
+
<table class='bodyTable'>
|
|
4
|
+
<tr>
|
|
5
|
+
<th>File</th>
|
|
6
|
+
<th>Total score</th>
|
|
7
|
+
<th>Methods</th>
|
|
8
|
+
<th>Average score</th>
|
|
9
|
+
<th>Highest score</th>
|
|
10
|
+
</tr>
|
|
11
|
+
<%
|
|
12
|
+
def cycle(first_value, second_value, iteration)
|
|
13
|
+
return first_value if iteration % 2 == 0
|
|
14
|
+
return second_value
|
|
15
|
+
end
|
|
16
|
+
pages.sort {|x,y| y.highest_score <=> x.highest_score }.each_with_index do |page, count| %>
|
|
17
|
+
<tr class='<%= cycle("a", "b", count) %>'>
|
|
18
|
+
<td><a href='flog/<%= page.path %>' target="_blank"><%= page.filename.sub('.txt', '.rb').gsub(Regexp.new("#{Continuous4r::WORK_DIR}/flog/"),'') %></a>  <i>(<a class="externalLink" href="xdoclet/<%= page.filename.sub('.txt', '.rb.html').gsub(Regexp.new("#{Continuous4r::WORK_DIR}/flog/"),'').gsub(/\//,'_') %>" target="_blank">view source</a>)</i></td>
|
|
19
|
+
<td class='score'><%= sprintf("%0.2f", page.score) %></td>
|
|
20
|
+
<td class='score'><%= page.scanned_methods.length %></td>
|
|
21
|
+
<td class='score'><%= sprintf("%0.2f", page.average_score) %></td>
|
|
22
|
+
<td class='score'><%= sprintf("%0.2f", page.highest_score) %></td>
|
|
23
|
+
</tr>
|
|
24
|
+
<% end %>
|
|
25
|
+
<tr>
|
|
26
|
+
<td><strong>Totals</strong></td>
|
|
27
|
+
<td class='score'><strong><%= sprintf("%0.2f", pages.inject(0){|sum, page| sum + page.score }) %></strong></td>
|
|
28
|
+
<td class='score'><strong><%= pages.inject(0){|sum, page| sum + page.scanned_methods.length } %></strong></td>
|
|
29
|
+
<td class='score'></td>
|
|
30
|
+
<td class='score'></td>
|
|
31
|
+
</tr>
|
|
32
|
+
</table>
|
|
33
|
+
<p>Generated on <%= Time.now.localtime %></p>
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
<html>
|
|
2
|
+
<head>
|
|
3
|
+
<style>
|
|
4
|
+
body {
|
|
5
|
+
background-color: #efefef;
|
|
6
|
+
margin: 20px;
|
|
7
|
+
padding: 0;
|
|
8
|
+
font: 12px verdana, arial, helvetica;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
table {
|
|
12
|
+
border-collapse: collapse;
|
|
13
|
+
border: 1px solid #666;
|
|
14
|
+
background: #fff;
|
|
15
|
+
margin-bottom: 20px;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
table tr.light {
|
|
19
|
+
background: #fff;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
table tr.dark {
|
|
23
|
+
background: #f9f9f9;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
table td, table th {
|
|
27
|
+
padding: 4px 10px;
|
|
28
|
+
font-size: 13px;
|
|
29
|
+
}
|
|
30
|
+
table th {
|
|
31
|
+
text-align: center;
|
|
32
|
+
color: #fc0;
|
|
33
|
+
background: #336;
|
|
34
|
+
font-weight: bold;
|
|
35
|
+
border: #d0d0d0 1px solid;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
table td {
|
|
39
|
+
border: #d0d0d0 1px solid;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
table td.score {
|
|
43
|
+
text-align: right;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.warning {
|
|
47
|
+
background: yellow;
|
|
48
|
+
}
|
|
49
|
+
</style>
|
|
50
|
+
</head>
|
|
51
|
+
<body>
|
|
52
|
+
<p>Score: <%= score %></p>
|
|
53
|
+
<% scanned_methods.each do |sm| %>
|
|
54
|
+
<p><strong><%= sm.name %> (<%= sm.score %>)</strong></p>
|
|
55
|
+
<table>
|
|
56
|
+
<tr>
|
|
57
|
+
<th>Score</th>
|
|
58
|
+
<th>Operator</th>
|
|
59
|
+
</tr>
|
|
60
|
+
<%
|
|
61
|
+
def cycle(first_value, second_value, iteration)
|
|
62
|
+
return first_value if iteration % 2 == 0
|
|
63
|
+
return second_value
|
|
64
|
+
end
|
|
65
|
+
sm.operators.each_with_index do |operator, count| %>
|
|
66
|
+
<tr class='<%= cycle("light", "dark", count) %>'>
|
|
67
|
+
<td class='score'><%= sprintf("%0.2f", operator.score) %></td>
|
|
68
|
+
<td class='score'><%= operator.operator %></td>
|
|
69
|
+
</tr>
|
|
70
|
+
<% end %>
|
|
71
|
+
</table>
|
|
72
|
+
<% end %>
|
|
73
|
+
</body>
|
|
74
|
+
</html>
|
data/lib/site/header.rhtml
CHANGED
|
@@ -7,35 +7,51 @@
|
|
|
7
7
|
generation_date = DateTime.now
|
|
8
8
|
%>
|
|
9
9
|
<html>
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
<head>
|
|
11
|
+
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
|
|
12
|
+
<title>Project Information - <%= project['name'] %></title>
|
|
13
|
+
<style type="text/css" media="all">
|
|
14
14
|
@import url("./style/maven-base.css");
|
|
15
15
|
@import url("./style/maven-theme.css");
|
|
16
16
|
</style>
|
|
17
17
|
</head>
|
|
18
18
|
<body class="composite">
|
|
19
19
|
<div id="banner">
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
20
|
+
<table style="width: 100%; border: 0px solid black;">
|
|
21
|
+
<tr>
|
|
22
|
+
<%
|
|
23
|
+
begin
|
|
24
|
+
if !project.company.nil? and !project.company.logo.nil? and !project.company.url.nil? and !project.company.name.nil? %>
|
|
25
|
+
<td><a target="_blank" href="<%= project.company.url.text %>" id="organizationLogo"><img alt="<%= project.company.denomination.text %>" title="<%= project.company.denomination.text %>" src="<%= project.company.logo.text %>"></a></td>
|
|
26
|
+
<% end
|
|
27
|
+
rescue
|
|
28
|
+
# XML error safe
|
|
29
|
+
end
|
|
30
|
+
%>
|
|
31
|
+
<td width="100%"> </td>
|
|
32
|
+
<td style="white-space: nowrap;"><a href="<%= project.url.text %>" id="projectLogo"><%= project['name'] %></a>  </td>
|
|
33
|
+
<% if !project.logo.nil? %>
|
|
34
|
+
<td><img src="<%= project.logo.text %>" align="absmiddle"/></td>
|
|
35
|
+
<% end %>
|
|
36
|
+
</tr>
|
|
37
|
+
</table>
|
|
38
|
+
<div class="clear"><hr></div>
|
|
30
39
|
</div>
|
|
31
40
|
<div id="breadcrumbs">
|
|
32
|
-
|
|
41
|
+
<%
|
|
42
|
+
if File.exist?(".git")
|
|
43
|
+
display_version = ", commit #{Utils.run_command("git log").split(/$/).select{ |l| l =~ /^commit / }.collect { |l| l[8..(l.length-1)] }[0]}"
|
|
44
|
+
end
|
|
45
|
+
if File.exist?(".svn")
|
|
46
|
+
get_head_log = Utils.run_command("svn log -r HEAD")
|
|
47
|
+
get_head_log_lines = get_head_log.split(/$/)
|
|
48
|
+
revision = get_head_log_lines[1].split(/ \| /)[0]
|
|
49
|
+
revision = revision[2..(revision.length-1)]
|
|
50
|
+
display_version = ", revision #{revision}"
|
|
51
|
+
end
|
|
52
|
+
%>
|
|
53
|
+
<div class="xleft">Last published: <%= generation_date.strftime("%Y-%m-%d") %> <span class="separator">|</span> Doc for <%= project['name'] %><%= display_version %></div>
|
|
33
54
|
<div class="xright">
|
|
34
|
-
<!-- a href="http://www..org/" class="externalLink" title="External Link">Assembla</a>
|
|
35
|
-
<span class="separator">|</span>
|
|
36
|
-
|
|
37
|
-
<a href="http://commons.apache.org/" class="externalLink" title="External Link">Commons</a> -->
|
|
38
|
-
Pas de liens
|
|
39
55
|
</div>
|
|
40
56
|
<div class="clear"><hr></div>
|
|
41
57
|
</div>
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
<%
|
|
2
|
-
|
|
3
|
-
require 'XmlElements'
|
|
4
|
-
project = XmlElements.fromString(File.read("continuous4r-project.xml"))
|
|
2
|
+
tasks = Continuous4r::TASKS
|
|
5
3
|
%>
|
|
6
4
|
<div id="leftColumn">
|
|
7
5
|
<div id="navcolumn">
|
|
@@ -11,17 +9,9 @@
|
|
|
11
9
|
<li class="collapsed"><a href="index.html">Project Info</a></li>
|
|
12
10
|
<li class="expanded"><strong><a href="continuous4r-reports.html">Project Reports</a></strong>
|
|
13
11
|
<ul>
|
|
14
|
-
<%
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
<li class="none"><a href="<%= task['name'] %>.html"><%= task['name'] %></a></li>
|
|
18
|
-
<%
|
|
19
|
-
end
|
|
20
|
-
rescue Exception => e
|
|
21
|
-
unless e.to_s == "no childs named 'task' found!"
|
|
22
|
-
raise e
|
|
23
|
-
end
|
|
24
|
-
end %>
|
|
12
|
+
<% tasks.each do |task| %>
|
|
13
|
+
<li class="none"><a href="<%= task %>.html"><%= task %></a></li>
|
|
14
|
+
<% end %>
|
|
25
15
|
</ul>
|
|
26
16
|
</li>
|
|
27
17
|
</ul>
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
<%
|
|
2
|
-
|
|
3
|
-
require 'XmlElements'
|
|
4
|
-
project = XmlElements.fromString(File.read("continuous4r-project.xml"))
|
|
2
|
+
tasks = Continuous4r::TASKS
|
|
5
3
|
%>
|
|
6
4
|
<div id="leftColumn">
|
|
7
5
|
<div id="navcolumn">
|
|
@@ -11,8 +9,8 @@
|
|
|
11
9
|
<li class="collapsed"><a href="index.html">Project Info</a></li>
|
|
12
10
|
<li class="expanded"><a href="continuous4r-reports.html">Project Reports</a>
|
|
13
11
|
<ul>
|
|
14
|
-
<%
|
|
15
|
-
<li class="none"><% if task
|
|
12
|
+
<% tasks.each do |task| %>
|
|
13
|
+
<li class="none"><% if task == current_task %><strong><% end %><a href="<%= task %>.html"><%= task %></a><% if task == current_task %></strong><% end %></li>
|
|
16
14
|
<% end %>
|
|
17
15
|
</ul>
|
|
18
16
|
</li>
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
pre {
|
|
2
|
+
background-color: #f1f1f3;
|
|
3
|
+
color: #112;
|
|
4
|
+
padding: 10px;
|
|
5
|
+
font-size: 1.1em;
|
|
6
|
+
overflow: auto;
|
|
7
|
+
margin: 4px 0px;
|
|
8
|
+
width: 95%;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
/* Syntax highlighting */
|
|
12
|
+
pre .normal {}
|
|
13
|
+
pre .comment { color: #005; font-style: italic; }
|
|
14
|
+
pre .keyword { color: #A00; font-weight: bold; }
|
|
15
|
+
pre .method { color: #077; }
|
|
16
|
+
pre .class { color: #074; }
|
|
17
|
+
pre .module { color: #050; }
|
|
18
|
+
pre .punct { color: #447; font-weight: bold; }
|
|
19
|
+
pre .symbol { color: #099; }
|
|
20
|
+
pre .string { color: #944; background: #FFE; }
|
|
21
|
+
pre .char { color: #F07; }
|
|
22
|
+
pre .ident { color: #004; }
|
|
23
|
+
pre .constant { color: #07F; }
|
|
24
|
+
pre .regex { color: #B66; background: #FEF; }
|
|
25
|
+
pre .number { color: #F99; }
|
|
26
|
+
pre .attribute { color: #5bb; }
|
|
27
|
+
pre .global { color: #7FB; }
|
|
28
|
+
pre .expr { color: #227; }
|
|
29
|
+
pre .escape { color: #277; }
|
|
30
|
+
pre .numline { color: #000; font-weight: bold; }
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# ==========================================================================
|
|
2
|
+
# Construction de la tache stats (statistiques du code Ruby)
|
|
3
|
+
# author: Vincent Dubois
|
|
4
|
+
# date: 06 fevrier 2009
|
|
5
|
+
# ==========================================================================
|
|
6
|
+
class StatsBuilder
|
|
7
|
+
include Utils
|
|
8
|
+
|
|
9
|
+
# Implementation de la construction de la tache
|
|
10
|
+
def build(project_name, auto_install, proxy_option)
|
|
11
|
+
# On lance la generation
|
|
12
|
+
puts " Building stats report..."
|
|
13
|
+
stats_result = Utils.run_command("rake stats")
|
|
14
|
+
stats_report = File.open("#{Continuous4r::WORK_DIR}/stats_body.html", "w")
|
|
15
|
+
stats_report.write(StatsFormatter.new(stats_result).to_html)
|
|
16
|
+
stats_report.close
|
|
17
|
+
end
|
|
18
|
+
end
|
data/lib/subversion_extractor.rb
CHANGED
|
@@ -1,41 +1,51 @@
|
|
|
1
1
|
require 'iconv'
|
|
2
|
+
|
|
2
3
|
# ====================================================
|
|
3
4
|
# Classe d'extraction des informations de Subversion
|
|
4
5
|
# Author: Vincent Dubois
|
|
6
|
+
# Date: 19 fevrier 2009
|
|
5
7
|
# ====================================================
|
|
6
8
|
module SubversionExtractor
|
|
7
9
|
|
|
8
10
|
# Methode qui permet de fabriquer le flux HTML a partir des informations
|
|
9
11
|
# presentes dans le referentiel
|
|
10
|
-
def self.extract_changelog scm_current_version,
|
|
11
|
-
|
|
12
|
-
begin
|
|
13
|
-
post_command = post_command + " --username " + scm.user.text
|
|
14
|
-
post_command = post_command + " --password " + scm.password.text
|
|
15
|
-
rescue
|
|
16
|
-
post_command = ""
|
|
17
|
-
end
|
|
18
|
-
get_head_log = `svn log -r 'HEAD'#{post_command}`
|
|
12
|
+
def self.extract_changelog scm_current_version, file_name
|
|
13
|
+
get_head_log = Utils.run_command("svn log -r HEAD")
|
|
19
14
|
get_head_log_lines = get_head_log.split(/$/)
|
|
20
15
|
revision = get_head_log_lines[1].split(/ \| /)[0]
|
|
21
16
|
revision = revision[2..(revision.length-1)]
|
|
22
|
-
|
|
17
|
+
# scm.url.text à remplacer par 'svn info'
|
|
18
|
+
svn_info = Utils.run_command("svn info")
|
|
19
|
+
svn_url = svn_info.split(/$/)[1].split(/^URL/)[1].strip.split(/: /)[1]
|
|
20
|
+
puts " Computing changelog for #{svn_url}, from revision #{scm_current_version} to revision #{revision}..."
|
|
23
21
|
i = 0
|
|
24
22
|
html = "<table class='bodyTable'><thead><th>Revision</th><th>Date</th><th>Author</th><th>File(s)</th><th>Comment</th></thead><tbody>"
|
|
25
23
|
(scm_current_version.to_i..revision.to_i).to_a.reverse_each do |rev|
|
|
26
24
|
puts " Changelog for revision #{rev}..."
|
|
27
25
|
rev_files = Array.new
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
# TODO Dans la suite, gérer les icônes ajout/modif/suppression
|
|
27
|
+
if rev == 1 #or (!scm['min_revision'].nil? and rev == scm['min_revision'].to_i)
|
|
28
|
+
rev_result = Utils.run_command("svn diff -r #{rev}").split(/$/).select{ |l| l =~ /^Index:/ }
|
|
29
|
+
rev_result.each do |line|
|
|
30
|
+
rev_files.push "<img src='images/added.png' align='absmiddle'/>#{line[8..(line.length-1)]}"
|
|
31
|
+
end
|
|
30
32
|
else
|
|
31
|
-
rev_result =
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
33
|
+
rev_result = Utils.run_command("svn diff -r #{rev-1}:#{rev} --summarize")
|
|
34
|
+
rev_result_lines = rev_result.split(/$/).collect { |l| l.gsub(Regexp.new("\n"), "") }
|
|
35
|
+
rev_result_lines.each do |line|
|
|
36
|
+
text = ''
|
|
37
|
+
if line[0..0] == 'A'
|
|
38
|
+
text = "<img src='images/added.png' align='absmiddle'/>"
|
|
39
|
+
elsif line[0..0] == 'M'
|
|
40
|
+
text = "<img src='images/modified.png' align='absmiddle'/>"
|
|
41
|
+
elsif line[0..0] == 'D'
|
|
42
|
+
text = "<img src='images/deleted.png' align='absmiddle'/>"
|
|
43
|
+
end
|
|
44
|
+
rev_files.push "#{text} #{line[7..(line.length-1)]}"
|
|
45
|
+
end
|
|
46
|
+
rev_files.pop
|
|
36
47
|
end
|
|
37
|
-
|
|
38
|
-
rev_log_result = `svn log -r #{rev}`
|
|
48
|
+
rev_log_result = Utils.run_command("svn log -r #{rev}")
|
|
39
49
|
rev_log_result_lines = rev_log_result.split(/$/)
|
|
40
50
|
rev_line = rev_log_result_lines[1].split(/ \| /)
|
|
41
51
|
html = html + "<tr class='#{ i % 2 == 0 ? 'a' : 'b'}'><td><strong>#{rev_line[0][2..(rev_line[0].length-1)]}</strong></td>"
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
<project name="FIXME project name" auto-install-gems="true" auto-install-tools="true" ignore-tests-failures="true">
|
|
2
|
+
<description>FIXME project description</description>
|
|
3
|
+
<url>FIXME project URL</url>
|
|
4
|
+
<logo>FIXME Logo URL</logo>
|
|
5
|
+
<company>
|
|
6
|
+
<denomination>FIXME your company name here</denomination>
|
|
7
|
+
<url>FIXME your company website URL here</url>
|
|
8
|
+
<logo>FIXME your company logo URL here</logo>
|
|
9
|
+
</company>
|
|
10
|
+
<members>
|
|
11
|
+
<member id="FIXME user login" name="FIXME user name" email="FIXME user email"
|
|
12
|
+
roles="FIXME user roles, separated by commas" company="FIXME company/ organisation name"/>
|
|
13
|
+
</members>
|
|
14
|
+
<bugtracker>
|
|
15
|
+
<tracker_type>[Trac|Bugzilla|Mantis|etc...]</tracker_type>
|
|
16
|
+
<tracker_url>BUGTRACKER_URL</tracker_url>
|
|
17
|
+
<tracker_account_create>BUGTRACKER_URL_ACCOUNT_CREATION</tracker_account_create>
|
|
18
|
+
<search>BUGTRACKER_URL_SEARCH_TICKETS</search>
|
|
19
|
+
<url>BUGTRACKER_URL_TICKETS_LIST</url>
|
|
20
|
+
<add>BUGTRACKER_URL_TICKET_ADD</add>
|
|
21
|
+
</bugtracker>
|
|
22
|
+
<!-- Gems mandatory for your project -->
|
|
23
|
+
<gems repository="http://gems.rubyforge.org/gems/">
|
|
24
|
+
<gem name="GEM_NAME" version="GEM_VERSION"/>
|
|
25
|
+
</gems>
|
|
26
|
+
</project>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Tache Rake pour la construction du site Continuous4R
|
|
2
|
+
namespace :continuous4r do
|
|
3
|
+
desc 'Clean any continuous4r builds'
|
|
4
|
+
task :clean do
|
|
5
|
+
if File.exist?(Continuous4r::WORK_DIR)
|
|
6
|
+
FileUtils.rm_rf(Continuous4r::WORK_DIR)
|
|
7
|
+
end
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
desc 'Initialize your project for continuous4r build'
|
|
11
|
+
task :init do
|
|
12
|
+
if !File.exist?("#{RAILS_ROOT}/continuous4r-project.xml")
|
|
13
|
+
FileUtils.copy_file(File.join(File.dirname(__FILE__), "continuous4r-project.xml"), "#{RAILS_ROOT}/continuous4r-project.xml")
|
|
14
|
+
else
|
|
15
|
+
puts "The continuous4r-project.xml file already exists. Either this project is already configured, or you should delete this file and re-run this command."
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
desc 'Build continuous4r Website for the current project'
|
|
20
|
+
task :build do
|
|
21
|
+
Continuous4r.generate_site
|
|
22
|
+
end
|
|
23
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# ==========================================================================
|
|
2
|
+
# Construction de la tache test (test unitaires du code ruby)
|
|
3
|
+
# author: Vincent Dubois
|
|
4
|
+
# date: 11 fevrier 2009
|
|
5
|
+
# ==========================================================================
|
|
6
|
+
class TestsBuilder
|
|
7
|
+
include Utils
|
|
8
|
+
|
|
9
|
+
# Implementation de la construction de la tache
|
|
10
|
+
def build(project_name, auto_install, proxy_option)
|
|
11
|
+
# On lance la generation
|
|
12
|
+
puts " Building tests report..."
|
|
13
|
+
if File.exist?("#{Continuous4r::WORK_DIR}/tests-run.html")
|
|
14
|
+
File.delete("#{Continuous4r::WORK_DIR}/tests-run.html")
|
|
15
|
+
end
|
|
16
|
+
tests_report = File.open("#{Continuous4r::WORK_DIR}/tests-run.html", "w")
|
|
17
|
+
html = TestsFormatter.new.to_html
|
|
18
|
+
tests_report.write(html)
|
|
19
|
+
tests_report.close
|
|
20
|
+
end
|
|
21
|
+
end
|