debian-mirror-gitlab/lib/gitlab/ci/pipeline/chain/helpers.rb
2019-12-04 20:38:33 +05:30

20 lines
433 B
Ruby

# frozen_string_literal: true
module Gitlab
module Ci
module Pipeline
module Chain
module Helpers
def error(message, config_error: false)
if config_error && command.save_incompleted
pipeline.yaml_errors = message
pipeline.drop!(:config_error)
end
pipeline.errors.add(:base, message)
end
end
end
end
end
end