Class: RepoMiner::Miners::Email

Inherits:
Object
  • Object
show all
Defined in:
lib/repo_miner/miners/email.rb

Instance Method Summary collapse

Instance Method Details

#analyse(commit) ⇒ Object



4
5
6
7
8
9
10
11
12
13
14
# File 'lib/repo_miner/miners/email.rb', line 4

def analyse(commit)
  # analyse commit
  committer_email = commit.rugged_commit.committer[:email]
  author_email = commit.rugged_commit.author[:email]

  # attach mined info to commit
  commit.add_data(:email, {
    committer: committer_email,
    author: author_email
  })
end