Class: Repo

Inherits:
Object
  • Object
show all
Defined in:
lib/repos_report/repo.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(directory) ⇒ Repo

Returns a new instance of Repo.



6
7
8
# File 'lib/repos_report/repo.rb', line 6

def initialize(directory)
  @directory = directory
end

Instance Attribute Details

#directoryObject

Returns the value of attribute directory.



4
5
6
# File 'lib/repos_report/repo.rb', line 4

def directory
  @directory
end

Instance Method Details

#concise_status(whitespace_padding) ⇒ Object



14
15
16
17
18
19
20
21
22
# File 'lib/repos_report/repo.rb', line 14

def concise_status(whitespace_padding)
  set_git_variables # Not needed unless this method is run

  if issues.any?
    message_with_issues(whitespace_padding).red
  else
    message_with_no_issues(whitespace_padding).green
  end
end

#project_name_lengthObject



10
11
12
# File 'lib/repos_report/repo.rb', line 10

def project_name_length
  project_name.length
end