Sha256: 5fe18743edb59200302d8d328bd5c0c3f43a84e8d51aada792f111c53bf333a1
Contents?: true
Size: 907 Bytes
Versions: 6
Compression:
Stored size: 907 Bytes
Contents
require 'albacore/support/albacore_helper' class NAnt extend AttrMethods include RunCommand include YAMLConfig include Logging attr_accessor :build_file attr_array :targets attr_hash :properties def initialize super() end def run command_parameters = [] command_parameters << "-buildfile:#{@build_file}" unless @build_file.nil? command_parameters << "#{build_properties}" unless @properties.nil? command_parameters << "#{build_targets}" unless @targets.nil? result = run_command "NAnt", command_parameters.join(" ") failure_msg = 'NAnt task Failed. See Build Log For Detail.' fail_with_message failure_msg if !result end private def build_targets @targets.join " " end def build_properties @properties.map {|key, value| "-D:#{key}=#{value}" }.join(" ") end end
Version data entries
6 entries across 6 versions & 1 rubygems