We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8776627 commit 3654612Copy full SHA for 3654612
lib/git/object.rb
@@ -53,6 +53,22 @@ def archive(file = nil, opts = {})
53
@base.lib.archive(@sha, file, opts)
54
end
55
56
+ def tree?
57
+ @type == 'tree'
58
+ end
59
+
60
+ def blob?
61
+ @type == 'blob'
62
63
64
+ def commit?
65
+ @type == 'commit'
66
67
68
+ def tag?
69
+ @type == 'tag'
70
71
72
73
74
0 commit comments