Sha256: f588e6adf89fc0efe7bd71ca28c0085b93dac5a412400f251d32ec30c3d44202
Contents?: true
Size: 1.26 KB
Versions: 19
Compression:
Stored size: 1.26 KB
Contents
module Dev module Cmd class Compile < Array def refresh puts_debug "Dev::Cmd::Compile.refresh" strip_auto_entries windows=RUBY_PLATFORM.include?("w32") # jamfiles # vcxproj Dir.glob('**/*.vcxproj').each { |vcxproj| self << "{:cmd=> '<paths,msbuild> #{vcxproj} /property:Configuration=Release /property:Platform=Win32', :auto=>true}" } if windows # csproj csbuild="<paths,msbuild>" csbuild="xbuild" if !RUBY_PLATFORM.include?("w32") Dir.glob('**/*.csproj').each { |csproj| platforms=Dev::Cmd::Compile.extract_platforms(csproj) platforms.each { |platform| skip=(!RUBY_PLATFORM.include?("w32") && platform=="x64") self << "{:cmd=> '#{csbuild} #{csproj} /property:Configuration=Release /property:Platform=\"#{platform}\" /p:OutputPath=./bin/#{platform}/Release', :auto=>true}" if !skip } } # gemspec Dir.glob("*.gemspec").each { |gs| self << "{:cmd=> 'gem build #{gs}', :capture_output=> false, :auto=> true}" } end def self.extract_platforms(filename) results = Array::new text=File.read(filename) text.scan(/(\w+)<\/Platform/).each{ | var_match | results << var_match[0].to_s if !results.include?(var_match[0].to_s)} results end end # class Compile end # module Cmd end # module Dev
Version data entries
19 entries across 19 versions & 1 rubygems