forked from digitalBush/Autofac.Settings
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrakefile.rb
40 lines (31 loc) · 939 Bytes
/
rakefile.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
require 'albacore'
PRODUCT_NAME = "Autofac.Settings"
BUILD_PATH = File.expand_path("build")
TOOLS_PATH = File.expand_path("tools")
LIB_PATH = File.expand_path("lib")
configuration = ENV['Configuration'] || "Debug"
task :default => :all
task :all => [:clean,:build,:specs,:copy]
task :clean do
rmtree BUILD_PATH
end
msbuild :build do |msb|
msb.properties :configuration => configuration
msb.targets :Clean, :Build
msb.verbosity = "minimal"
msb.solution = "#{PRODUCT_NAME}.sln"
end
mspec :specs => [:build] do |mspec|
mspec.command = "packages/Machine.Specifications.0.6.2/tools/mspec-clr4.exe"
mspec.assemblies Dir.glob('specs/**/bin/*Debug/*Specs.dll')
end
task :copy => [:specs] do
Dir.glob("src/**/*.csproj") do |proj|
name=File.basename(proj,".csproj")
puts "Copying output for #{name}"
src=File.dirname(proj)
dest = "#{BUILD_PATH}/#{name}/"
mkdir_p(dest)
cp_r("#{src}/bin/#{configuration}/.",dest)
end
end