Class: Ghee::API::Repos::Pulls::Proxy
- Inherits:
-
ResourceProxy
- Object
- ResourceProxy
- Ghee::API::Repos::Pulls::Proxy
- Includes:
- CUD
- Defined in:
- lib/ghee/api/pulls.rb
Instance Attribute Summary
Attributes inherited from ResourceProxy
#connection, #current_page, #pagination, #params, #path_prefix, #total
Instance Method Summary collapse
Methods included from CUD
Methods inherited from ResourceProxy
accept_header, #all, #all_parallel, #build_prefix, #initialize, #method_missing, #paginate, #raw, #subject
Constructor Details
This class inherits a constructor from Ghee::ResourceProxy
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Ghee::ResourceProxy
Instance Method Details
#commits ⇒ Object
17 18 19 |
# File 'lib/ghee/api/pulls.rb', line 17 def commits connection.get("#{path_prefix}/commits").body end |
#files ⇒ Object
21 22 23 |
# File 'lib/ghee/api/pulls.rb', line 21 def files connection.get("#{path_prefix}/files").body end |
#merge!(message = nil) ⇒ Object
29 30 31 32 |
# File 'lib/ghee/api/pulls.rb', line 29 def merge!(=nil) params = ? {:commit_message=>} : {} connection.put("#{path_prefix}/merge", params).body end |
#merge? ⇒ Boolean
25 26 27 |
# File 'lib/ghee/api/pulls.rb', line 25 def merge? connection.get("#{path_prefix}/merge").status == 204 end |