module Gitlabci::Bundle::Update::Mr

Constants

VERSION

Public Class Methods

assert_env_keys() click to toggle source
# File lib/gitlabci/bundle/update/mr.rb, line 19
def self.assert_env_keys
  %w[
    OCTOKIT_ACCESS_TOKEN
    GITLAB_API_ENDPOINT
    GITLAB_API_PRIVATE_TOKEN
    CI_PROJECT_PATH
    CI_COMMIT_REF_NAME
  ].each do |key|
    assert_env_key(key)
  end
end

Private Class Methods

assert_env_key(key) click to toggle source
# File lib/gitlabci/bundle/update/mr.rb, line 31
def self.assert_env_key(key)
  raise MissingKeyError, "#{key} is required" if !ENV[key] || ENV[key].empty?
end