Class: Geet::Services::ListPrs
- Inherits:
-
Object
- Object
- Geet::Services::ListPrs
- Extended by:
- T::Sig
- Defined in:
- lib/geet/services/list_prs.rb
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(repository, out: $stdout) ⇒ ListPrs
constructor
A new instance of ListPrs.
Constructor Details
#initialize(repository, out: $stdout) ⇒ ListPrs
Returns a new instance of ListPrs.
12 13 14 15 |
# File 'lib/geet/services/list_prs.rb', line 12 def initialize(repository, out: $stdout) @repository = repository @out = out end |
Instance Method Details
#execute ⇒ Object
20 21 22 23 24 25 26 |
# File 'lib/geet/services/list_prs.rb', line 20 def execute prs = @repository.prs prs.each do |pr| @out.puts "#{pr.number}. #{pr.title} (#{pr.link})" end end |