Sha256: 7c93c2bf18c6755bc6aca194c80e78b33895300d708d73b8306c407682b4c72d

Contents?: true

Size: 525 Bytes

Versions: 3

Compression:

Stored size: 525 Bytes

Contents

# frozen_string_literal: true

require_relative '../hash_initializable'

module GitStats
  module GitData
    class Tree
      include GitStats::HashInitializable

      attr_reader :repo, :relative_path

      def authors
        @authors ||= run_and_parse("git shortlog -se #{commit_range}").map do |author|
          Author.new(repo: self, name: author[:name], email: author[:email])
        end
      end

      def ==(other)
        repo == other.repo && relative_path == other.relative_path
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
nova_git_stats-2.4.2 lib/git_stats/git_data/tree.rb
nova_git_stats-2.4.1 lib/git_stats/git_data/tree.rb
nova_git_stats-2.4.0 lib/git_stats/git_data/tree.rb