Class: PairingMatrix::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/pairing_matrix/config/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(repos, authors_regex, github_access_token, github_repos) ⇒ Config

Returns a new instance of Config.



5
6
7
8
9
10
# File 'lib/pairing_matrix/config/config.rb', line 5

def initialize(repos, authors_regex, github_access_token, github_repos)
  @repos = repos
  @authors_regex = authors_regex
  @github_access_token = github_access_token
  @github_repos = github_repos
end

Instance Attribute Details

#authors_regexObject (readonly)

Returns the value of attribute authors_regex.



3
4
5
# File 'lib/pairing_matrix/config/config.rb', line 3

def authors_regex
  @authors_regex
end

#github_access_tokenObject (readonly)

Returns the value of attribute github_access_token.



3
4
5
# File 'lib/pairing_matrix/config/config.rb', line 3

def github_access_token
  @github_access_token
end

#github_reposObject (readonly)

Returns the value of attribute github_repos.



3
4
5
# File 'lib/pairing_matrix/config/config.rb', line 3

def github_repos
  @github_repos
end

#reposObject (readonly)

Returns the value of attribute repos.



3
4
5
# File 'lib/pairing_matrix/config/config.rb', line 3

def repos
  @repos
end

Instance Method Details

#fetch_from_github?Boolean

Returns:

  • (Boolean)


12
13
14
# File 'lib/pairing_matrix/config/config.rb', line 12

def fetch_from_github?
  !@github_repos.nil? && !@github_repos.empty?
end

#has_github_access_token?Boolean

Returns:

  • (Boolean)


16
17
18
# File 'lib/pairing_matrix/config/config.rb', line 16

def has_github_access_token?
  !@github_access_token.nil? && !@github_access_token.empty?
end