Sha256: 60c085aefaa7ff6512c2beca5d891b1c5e4870f0a8a5852b10ae14befee17fc3
Contents?: true
Size: 1.64 KB
Versions: 2
Compression:
Stored size: 1.64 KB
Contents
require "albacore/albacoretask" require "albacore/config/fluentmigratorconfig" class FluentMigrator TaskName = :fluentmigrator include Albacore::Task include Albacore::RunCommand include Configuration::FluentMigrator attr_reader :out, :verbose, :preview attr_accessor :target, :provider, :connection, :namespace, :out_file, :steps, :tag, :task, :version, :script_directory, :profile, :timeout def initialize() super() update_attributes(fluentmigrator.to_hash) end def execute() result = run_command("FluentMigrator", get_command_parameters) fail_with_message("Fluent Migrator failed, see the build log for more details.") unless result end def get_command_parameters p = [] p << "/target=\"#{@target}\"" p << "/provider=#{@provider}" p << "/connection=\"#{@connection}\"" p << "/ns=#{@namespace}" if @namespace p << "/out" if @out p << "/outfile=\"#{@out_file}\"" if @out_file p << "/preview" if @preview p << "/steps=#{@steps}" if @steps p << "/task=#{@task}" if @task p << "/version=#{@version}" if @version p << "/verbose=#{@verbose}" if @verbose p << "/wd=\"#{@script_directory}\"" if @script_directory p << "/profile=#{@profile}" if @profile p << "/timeout=#{@timeout}" if @timeout p << "/tag=#{@tag}" if @tag p end def verbose @verbose = true end def preview @preview = true end def out @out = true end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
albacore-1.0.0 | lib/albacore/fluentmigrator.rb |
albacore-1.0.0.rc.3 | lib/albacore/fluentmigrator.rb |