rake-dotnet 0.1.0 → 0.1.1
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 +12 -0
- data/Rakefile +1 -1
- data/lib/rake_dotnet.rb +29 -21
- metadata +5 -7
data/History.txt
CHANGED
@@ -1,3 +1,15 @@
|
|
1
|
+
=== 0.1.1 / 2009-05-20
|
2
|
+
|
3
|
+
* NEW: Add FxCop -> TeamCity code-inspections reporting via TeamCity's service-messages feature
|
4
|
+
* CHANGE: MsBuild; use constants rather than hard-codings for verbosity of output and source-directory
|
5
|
+
* FIX: If BUILD_NUMBER environment variable is not a number, use 0 (since only numbers are valid to the AssemblyFileVersion and AssemblyVersion attributes)
|
6
|
+
|
7
|
+
=== 0.1.0 / 2009-05-08
|
8
|
+
|
9
|
+
* NEW: Add the ability for ncover.reporting to generate more than one report at a time
|
10
|
+
|
11
|
+
|
12
|
+
|
1
13
|
=== 0.0.12 / 2009-05-01
|
2
14
|
|
3
15
|
* FIX: Automatically create {project}/Properties directories when generating AssemblyInfo.cs files (git does not version empty directories)
|
data/Rakefile
CHANGED
@@ -5,7 +5,7 @@ require 'hoe'
|
|
5
5
|
require 'Pathname'
|
6
6
|
require 'rake/clean'
|
7
7
|
|
8
|
-
Hoe.new('rake-dotnet', '0.1.
|
8
|
+
Hoe.new('rake-dotnet', '0.1.1') do |p|
|
9
9
|
p.author = 'Peter Mounce'
|
10
10
|
p.description = 'Making a .NET build-automation dev\'s life easier, one angle-bracket at a time'
|
11
11
|
p.email = 'pete@neverrunwithscissors.com'
|
data/lib/rake_dotnet.rb
CHANGED
@@ -188,7 +188,7 @@ module Rake
|
|
188
188
|
@suites_dir = params[:suites_dir] || File.join(OUT_DIR, 'bin')
|
189
189
|
@dll_list = FileList.new
|
190
190
|
@deps = params[:deps] || []
|
191
|
-
@fxcop_options =
|
191
|
+
@fxcop_options = params[:fxcop_options] || {}
|
192
192
|
if @fxcop_options[:apply_out_xsl].nil? || @fxcop_options[:apply_out_xsl] == false
|
193
193
|
@name += '.xml'
|
194
194
|
else
|
@@ -212,9 +212,15 @@ module Rake
|
|
212
212
|
runner.run
|
213
213
|
end
|
214
214
|
|
215
|
-
task :fxcop,[:
|
216
|
-
args.with_defaults(:
|
217
|
-
|
215
|
+
task :fxcop,[:include_globs, :exclude_globs] do |t, args|
|
216
|
+
args.with_defaults(:include_globs => "#{@suites_dir}/**/*#{@product_name}*.dll")
|
217
|
+
args.include_globs.each do |g|
|
218
|
+
@dll_list.include g
|
219
|
+
end
|
220
|
+
args.with_defaults(:exclude_globs => "#{@suites_dir}/*Tests*.dll")
|
221
|
+
args.exclude_globs.each do |g|
|
222
|
+
@dll_list.exclude g
|
223
|
+
end
|
218
224
|
Rake::FileTask[@name].invoke
|
219
225
|
end
|
220
226
|
|
@@ -283,6 +289,7 @@ class FxCop
|
|
283
289
|
def run
|
284
290
|
puts cmd if VERBOSE
|
285
291
|
sh cmd
|
292
|
+
puts "##teamcity[importData type='FxCop' path='#{File.expand_path(@out_file)}']" if ENV['BUILD_NUMBER']
|
286
293
|
end
|
287
294
|
end
|
288
295
|
|
@@ -293,7 +300,7 @@ module Rake
|
|
293
300
|
@src_path = params[:src_path] || File.join(PRODUCT_ROOT, 'src')
|
294
301
|
@target_path = params[:target_path] || File.join(OUT_DIR, 'bin')
|
295
302
|
@deps = params[:deps] || []
|
296
|
-
@configuration = params[:configuration] ||
|
303
|
+
@configuration = params[:configuration] || CONFIGURATION
|
297
304
|
@glob = params[:glob] || "#{@src_path}/*"
|
298
305
|
|
299
306
|
yield self if block_given?
|
@@ -420,8 +427,8 @@ module Rake
|
|
420
427
|
|
421
428
|
def initialize(params={})
|
422
429
|
@configuration = params[:configuration] || CONFIGURATION
|
423
|
-
@src_dir = params[:src_dir] ||
|
424
|
-
@verbosity = params[:verbosity] || 'm'
|
430
|
+
@src_dir = params[:src_dir] || SRC_DIR
|
431
|
+
@verbosity = params[:verbosity] || MSBUILD_VERBOSITY || 'm'
|
425
432
|
@working_dir = params[:working_dir] || '.'
|
426
433
|
@deps = params[:deps] || []
|
427
434
|
|
@@ -562,8 +569,8 @@ module Rake
|
|
562
569
|
|
563
570
|
end
|
564
571
|
|
565
|
-
|
566
|
-
|
572
|
+
desc "Generate ncover coverage report(s), on all coverage files, merged together"
|
573
|
+
task :ncover_reports => [:ncover_profile] do
|
567
574
|
# ncover lets us use *.coverage.xml to merge together files
|
568
575
|
include = [File.join(@report_dir, '*.coverage.xml')]
|
569
576
|
@ncover_reporting_options[:name] = 'merged'
|
@@ -571,10 +578,7 @@ module Rake
|
|
571
578
|
ncr.run
|
572
579
|
end
|
573
580
|
|
574
|
-
|
575
|
-
task :ncover_summary => [:ncover_profile, ncover_summary_report_html]
|
576
|
-
|
577
|
-
task :clean_coverage do
|
581
|
+
task :clobber_ncover do
|
578
582
|
rm_rf @report_dir
|
579
583
|
end
|
580
584
|
|
@@ -635,10 +639,8 @@ class NCoverReporting
|
|
635
639
|
@exe = params[:ncover_reporting_exe] || File.join(TOOLS_DIR, 'ncover', arch, 'ncover.reporting.exe')
|
636
640
|
|
637
641
|
# required
|
638
|
-
@
|
639
|
-
@
|
640
|
-
@format = params[:report_format] || 'html' # can be xml or html
|
641
|
-
@output_path = File.join(@report_dir, @name + '.' + @report + '.' + @format)
|
642
|
+
@reports = params[:reports] || ['Summary', 'UncoveredCodeSections']
|
643
|
+
@output_path = File.join(@report_dir)
|
642
644
|
|
643
645
|
# optional
|
644
646
|
@build_id = params[:build_id] || RDNVERSION
|
@@ -657,8 +659,12 @@ class NCoverReporting
|
|
657
659
|
"//bi #{@build_id.to_s}"
|
658
660
|
end
|
659
661
|
|
660
|
-
def
|
661
|
-
|
662
|
+
def output_reports
|
663
|
+
cmd = ''
|
664
|
+
@reports.each do |r|
|
665
|
+
cmd += "//or #{r} "
|
666
|
+
end
|
667
|
+
return cmd
|
662
668
|
end
|
663
669
|
|
664
670
|
def op
|
@@ -670,7 +676,7 @@ class NCoverReporting
|
|
670
676
|
end
|
671
677
|
|
672
678
|
def cmd
|
673
|
-
"\"#{@exe}\" #{coverage_files} #{bi} #{
|
679
|
+
"\"#{@exe}\" #{coverage_files} #{bi} #{output_reports} #{op} #{so}"
|
674
680
|
end
|
675
681
|
|
676
682
|
def run
|
@@ -873,7 +879,9 @@ class Versioner
|
|
873
879
|
end
|
874
880
|
|
875
881
|
def build
|
876
|
-
|
882
|
+
bn = ENV['BUILD_NUMBER']
|
883
|
+
return 0 if bn == nil || !bn.match(/\d+/)
|
884
|
+
return bn
|
877
885
|
end
|
878
886
|
|
879
887
|
def revision
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rake-dotnet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter MouncePeter Mounce
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-05-
|
12
|
+
date: 2009-05-20 00:00:00 +01:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -30,7 +30,7 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 1.
|
33
|
+
version: 1.11.0
|
34
34
|
version:
|
35
35
|
description: Making a .NET build-automation dev's life easier, one angle-bracket at a time
|
36
36
|
email: pete@neverrunwithscissors.compete@neverrunwithscissors.com
|
@@ -52,8 +52,6 @@ files:
|
|
52
52
|
- test/test_rake_dotnet.rb
|
53
53
|
has_rdoc: true
|
54
54
|
homepage: http://blog.neverrunwithscissors.com/tag/rake-dotnet
|
55
|
-
licenses: []
|
56
|
-
|
57
55
|
post_install_message:
|
58
56
|
rdoc_options:
|
59
57
|
- --main
|
@@ -75,9 +73,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
75
73
|
requirements: []
|
76
74
|
|
77
75
|
rubyforge_project: rake-dotnet
|
78
|
-
rubygems_version: 1.3.
|
76
|
+
rubygems_version: 1.3.1
|
79
77
|
signing_key:
|
80
|
-
specification_version:
|
78
|
+
specification_version: 2
|
81
79
|
summary: Build automation for .NET builds
|
82
80
|
test_files:
|
83
81
|
- test/test_rake_dotnet.rb
|