Sha256: 1cb8a211e4ea0d1064dfa5ef28c2bbf8725a6589886d6f19119260fa5c3c6868

Contents?: true

Size: 588 Bytes

Versions: 2

Compression:

Stored size: 588 Bytes

Contents

# frozen_string_literal: true

module Git
  module Lint
    module Branches
      module Environments
        # Provides GitHub Action build environment feature branch information.
        class GitHubAction
          def initialize repository: GitPlus::Repository.new
            @repository = repository
          end

          def name
            "origin/#{repository.branch_name}"
          end

          def commits
            repository.commits "origin/master..#{name}"
          end

          private

          attr_reader :repository
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
git-lint-2.1.0 lib/git/lint/branches/environments/git_hub_action.rb
git-lint-2.0.0 lib/git/lint/branches/environments/git_hub_action.rb