Updating distribution
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module CircleCI
|
||||
class Audit
|
||||
include IssueParser
|
||||
|
||||
def initialize(issue_content, _)
|
||||
@organization = parameter_from_issue("Organization", issue_content)
|
||||
end
|
||||
|
||||
def to_a
|
||||
return if @organization.nil?
|
||||
|
||||
["--circle-ci-organization", @organization]
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,21 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module CircleCI
|
||||
class DryRun
|
||||
include IssueParser
|
||||
|
||||
def initialize(issue_content, command)
|
||||
# TODO: manually test this
|
||||
@organization = parameter_from_issue("Organization", issue_content)
|
||||
@project = command.options["project"]
|
||||
end
|
||||
|
||||
def to_a
|
||||
args = []
|
||||
args.concat(["--circle-ci-organization", @organization]) unless @organization.nil?
|
||||
args.concat(["--circle-ci-project", @project]) unless @project.nil?
|
||||
|
||||
return args unless args.empty?
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,22 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module CircleCI
|
||||
class Migrate
|
||||
include IssueParser
|
||||
|
||||
def initialize(issue_content, command)
|
||||
@organization = parameter_from_issue("Organization", issue_content)
|
||||
@project = command.options["project"]
|
||||
@target_url = command.options["target-url"]
|
||||
end
|
||||
|
||||
def to_a
|
||||
args = []
|
||||
args.concat(["--circle-ci-organization", @organization]) unless @organization.nil?
|
||||
args.concat(["--circle-ci-project", @project]) unless @project.nil?
|
||||
args.concat(["--target-url", @target_url]) unless @target_url.nil?
|
||||
|
||||
return args unless args.empty?
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user