Module: Octokit::Client::Objects
- Included in:
- Octokit::Client
- Defined in:
- lib/octokit/client/objects.rb
Instance Method Summary collapse
- #blob(repo, tree_sha, path, options = {}) ⇒ Object
- #blob_metadata(repo, tree_sha, options = {}) ⇒ Object (also: #blob_meta)
- #blobs(repo, tree_sha, options = {}) ⇒ Object
- #raw(repo, sha, options = {}) ⇒ Object
- #tree(repo, tree_sha, options = {}) ⇒ Object
- #tree_metadata(repo, tree_sha, options = {}) ⇒ Object (also: #tree_meta)
Instance Method Details
#blob(repo, tree_sha, path, options = {}) ⇒ Object
8 9 10 |
# File 'lib/octokit/client/objects.rb', line 8 def blob(repo, tree_sha, path, ={}) get("/api/v2/json/blob/show/#{Repository.new(repo)}/#{tree_sha}/#{path}", )['blob'] end |
#blob_metadata(repo, tree_sha, options = {}) ⇒ Object Also known as: blob_meta
16 17 18 |
# File 'lib/octokit/client/objects.rb', line 16 def (repo, tree_sha, ={}) get("/api/v2/json/blob/full/#{Repository.new(repo)}/#{tree_sha}", )['blobs'] end |
#blobs(repo, tree_sha, options = {}) ⇒ Object
12 13 14 |
# File 'lib/octokit/client/objects.rb', line 12 def blobs(repo, tree_sha, ={}) get("/api/v2/json/blob/all/#{Repository.new(repo)}/#{tree_sha}", )['blobs'] end |
#raw(repo, sha, options = {}) ⇒ Object
26 27 28 |
# File 'lib/octokit/client/objects.rb', line 26 def raw(repo, sha, ={}) get("/api/v2/json/blob/show/#{Repository.new(repo)}/#{sha}", , 2, true, true).body end |
#tree(repo, tree_sha, options = {}) ⇒ Object
4 5 6 |
# File 'lib/octokit/client/objects.rb', line 4 def tree(repo, tree_sha, ={}) get("/api/v2/json/tree/show/#{Repository.new(repo)}/#{tree_sha}", )['tree'] end |
#tree_metadata(repo, tree_sha, options = {}) ⇒ Object Also known as: tree_meta
21 22 23 |
# File 'lib/octokit/client/objects.rb', line 21 def (repo, tree_sha, ={}) get("/api/v2/json/tree/full/#{Repository.new(repo)}/#{tree_sha}", )['tree'] end |