require 'KCommercialPipeline/command/command' require 'KCommercialPipeline/core/kim_cfg' require 'KCommercialPipeline/core/version_pipeline/release_check' module KCommercial module KCPipeline class Command class CheckReleaseCMD < Command attr_reader :branch_name self.command = 'check_release' self.version = KCommercialPipeline::VERSION self.summary = '校验release分支代码是否同步到develop' def self.options [ %w[--branch_name 需要校验的release分支,选填], ].concat(super ) end def initialize(argv) @branch_name = argv.option('branch_name') || "" super end def run if @branch_name.nil? || @branch_name.empty? ReleaseCheck.new().check_all else ReleaseChecker.new(@branch_name).run! end end end end end end