summaryrefslogtreecommitdiffstats
path: root/lib/git/object.rb
diff options
context:
space:
mode:
authorscott Chacon <schacon@agadorsparticus.(none)>2007-11-27 08:42:26 -0800
committerscott Chacon <schacon@agadorsparticus.(none)>2007-11-27 08:42:26 -0800
commit6bbead02aa2a60e7d50e68f3b2c98a14c26b2d81 (patch)
tree6233897a4ff9b1eec589d47a5a4a5eee458fa19f /lib/git/object.rb
parentb7a7d204bad7de8696ac800c3d1e608bdc344a38 (diff)
downloadthird_party-ruby-git-6bbead02aa2a60e7d50e68f3b2c98a14c26b2d81.zip
third_party-ruby-git-6bbead02aa2a60e7d50e68f3b2c98a14c26b2d81.tar.gz
third_party-ruby-git-6bbead02aa2a60e7d50e68f3b2c98a14c26b2d81.tar.xz
added ls-tree to gitr
Diffstat (limited to 'lib/git/object.rb')
-rw-r--r--lib/git/object.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/git/object.rb b/lib/git/object.rb
index 97a1a17..04102bc 100644
--- a/lib/git/object.rb
+++ b/lib/git/object.rb
@@ -136,8 +136,8 @@ module Git
@trees = {}
@blobs = {}
data = @base.lib.ls_tree(@objectish)
- data['tree'].each { |k, d| @trees[k] = Tree.new(@base, d[:sha], d[:mode]) }
- data['blob'].each { |k, d| @blobs[k] = Blob.new(@base, d[:sha], d[:mode]) }
+ data['tree'].each { |k, d| @trees[k] = Git::Object::Tree.new(@base, d[:sha], d[:mode]) }
+ data['blob'].each { |k, d| @blobs[k] = Git::Object::Blob.new(@base, d[:sha], d[:mode]) }
end
end
@@ -213,8 +213,8 @@ module Git
end
@committer = Git::Author.new(data['committer'])
@author = Git::Author.new(data['author'])
- @tree = Tree.new(@base, data['tree'])
- @parents = data['parent'].map{ |sha| Commit.new(@base, sha) }
+ @tree = Git::Object::Tree.new(@base, data['tree'])
+ @parents = data['parent'].map{ |sha| Git::Object::Commit.new(@base, sha) }
@message = data['message'].chomp
end
@@ -259,7 +259,7 @@ module Git
if sha == ''
raise Git::GitTagNameDoesNotExist.new(objectish)
end
- return Tag.new(base, sha, objectish)
+ return Git::Object::Tag.new(base, sha, objectish)
else
if !type
type = base.lib.object_type(objectish)