Permalink
Browse files

moved project

  • Loading branch information...
1 parent bda6513 commit ef2f2c0061a753d3303c54ff59402333ace46d97 @schacon committed Nov 8, 2010
Showing with 4 additions and 829 deletions.
  1. +0 −13 API
  2. +0 −21 LICENSE
  3. +4 −88 README.md
  4. +0 −107 Rakefile
  5. +0 −64 benchmarks.rb
  6. +0 −9 ext/ribbit/extconf.rb
  7. +0 −255 ext/ribbit/ribbit.c
  8. +0 −3 lib/ribbit/version.rb
  9. +0 −20 ribbit.gemspec
  10. +0 −1 test/fixtures/testrepo.git/HEAD
  11. +0 −6 test/fixtures/testrepo.git/config
  12. +0 −1 test/fixtures/testrepo.git/description
  13. BIN test/fixtures/testrepo.git/index
  14. +0 −6 test/fixtures/testrepo.git/info/exclude
  15. +0 −2 test/fixtures/testrepo.git/logs/HEAD
  16. +0 −2 test/fixtures/testrepo.git/logs/refs/heads/master
  17. BIN test/fixtures/testrepo.git/objects/13/85f264afb75a56a5bec74243be9b367ba4ca08
  18. BIN test/fixtures/testrepo.git/objects/18/1037049a54a1eb5fab404658a3a250b44335d7
  19. BIN test/fixtures/testrepo.git/objects/18/10dff58d8a660512d4832e740f692884338ccd
  20. BIN test/fixtures/testrepo.git/objects/45/b983be36b73c0788dc9cbcb76cbb80fc7bb057
  21. +0 −2 test/fixtures/testrepo.git/objects/4a/202b346bb0fb0db7eff3cffeb3c70babbd2045
  22. +0 −2 test/fixtures/testrepo.git/objects/5b/5b025afb0b4c913b4c338a42934a3863bf3644
  23. BIN test/fixtures/testrepo.git/objects/75/057dd4114e74cca1d750d0aee1647c903cb60a
  24. BIN test/fixtures/testrepo.git/objects/81/4889a078c031f61ed08ab5fa863aea9314344d
  25. BIN test/fixtures/testrepo.git/objects/84/96071c1b46c854b31185ea97743be6a8774479
  26. +0 −3 test/fixtures/testrepo.git/objects/9f/d738e8f7967c078dceed8190330fc8648ee56a
  27. +0 −2 test/fixtures/testrepo.git/objects/a4/a7dce85cf63874e984719f4fdd239f5145052f
  28. BIN test/fixtures/testrepo.git/objects/a7/1586c1dfe8a71c6cbf6c129f404c5642ff31bd
  29. BIN test/fixtures/testrepo.git/objects/a8/233120f6ad708f843d861ce2b7228ec4e3dec6
  30. +0 −3 test/fixtures/testrepo.git/objects/be/3563ae3f795b2b4353bcce3a527ad0a4f7f644
  31. +0 −3 test/fixtures/testrepo.git/objects/c4/7800c7266a2be04c571c04d5a6614691ea99bd
  32. BIN test/fixtures/testrepo.git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391
  33. BIN test/fixtures/testrepo.git/objects/f6/0079018b664e4e79329a7ef9559c8d9e0378d1
  34. BIN test/fixtures/testrepo.git/objects/fa/49b077972391ad58037050f2a75f74e3671e92
  35. BIN test/fixtures/testrepo.git/objects/fd/093bff70906175335656e6ce6ae05783708765
  36. BIN test/fixtures/testrepo.git/objects/pack/pack-d7c6adf9f61318f041845b01440d09aa7a91e1b5.idx
  37. BIN test/fixtures/testrepo.git/objects/pack/pack-d7c6adf9f61318f041845b01440d09aa7a91e1b5.pack
  38. +0 −2 test/fixtures/testrepo.git/packed-refs
  39. +0 −1 test/fixtures/testrepo.git/refs/heads/master
  40. +0 −33 test/lib_test.rb
  41. +0 −22 test/odb_pack_test.rb
  42. +0 −56 test/odb_test.rb
  43. +0 −27 test/test_helper.rb
  44. +0 −75 test/walker_test.rb
View
13 API
@@ -1,13 +0,0 @@
-= General Library
-
-Ribbit::Lib
- * hex_to_raw(SHA_HEX)
- * raw_to_hex(SHA_RAW)
-
-
-= Object Database Class
-
-Ribbit::Odb
- * new(path)
- - exists(SHA_HEX)
-
View
21 LICENSE
@@ -1,21 +0,0 @@
-The MIT License
-
-Copyright (c) 2010 Scott Chacon
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
View
@@ -1,90 +1,6 @@
-Ribbit - libgit2 bindings in Ruby
-===================================
+= Moved =
-Ribbit is a Ruby bindings to the libgit2 linkable C Git library. This is
-for testing and using the libgit2 library in a language that is awesome.
-
-INSTALLING AND RUNNING
-========================
-
-First you need to install libgit2:
-
- $ git clone git://repo.or.cz/libgit2.git
- $ cd libgit2
- $ make
- $ make install
-
-Next, you need to install rake-compiler:
-
- $ sudo gem install rake-compiler
-
-Now that those are installed, you can install Ribbit:
-
- $ git clone git://github.com/schacon/ribbit.git
- $ cd ribbit
- $ rake compile
- $ rake test
-
-
-API
-==============
-
-There is a general library for some basic Gitty methods. So far, just converting
-a raw sha (20 bytes) into a readable hex sha (40 char).
-
- raw = Ribbit::Lib.hex_to_raw(hex_sha)
- hex = Ribbit::Lib.raw_to_hex(20_byte_raw_sha)
-
-There is an Odb class that you can instantiate with a path (currently the 'objects'
-path in the .git directory, but I'll probably change that soon - patch, anybody?).
-This lets you check for objects, read raw object data, write raw object data and
-get a hash (SHA1 checksum) of what contents would be without writing them out.
-
- odb = Ribbit::Odb.new("/opt/repo.git/objects") # takes the object path, currently
-
- bool = odb.exists(hex_sha)
- data, length, type = odb.read(hex_sha) # or false if object does not exist
- hex_sha = odb.hash(content, type) # 'commit', 'blob', 'tree', 'tag'
- hex_sha = odb.write("my content\n", "blob")
-
-Finally, there is a Walker class that currently takes an object path (probably will
-eventually change this to just be instantiated from an Odb, like `walker = odb.walker`
-rather than seperately instantiated with the same path). You can push head SHAs
-onto the walker, then call next to get a list of the reachable commit objects, one
-at a time. You can also hide() commits if you are not interested in anything beneath
-them (useful for a `git log master ^origin/master` type deal).
-
- walker = Ribbit::Walker.new(path) # also takes object path
-
- walker.push(hex_sha_interesting)
- walker.hide(hex_sha_uninteresting)
- hex_sha = walker.next # false if none left
- walker.reset
-
-
-TODO
-==============
-
-I will try to keep this up to date with the working public API available in
-the libgit2 linkable library. Whatever is available there should be here
-as well.
-
-
-CONTRIBUTING
-==============
-
-Fork schacon/ribbit on GitHub, make it awesomer (preferably in a branch named
-for the topic), send a pull request.
-
-
-AUTHORS
-==============
-
-Scott Chacon <schacon@gmail.com>
-
-
-LICENSE
-==============
-
-MIT.
+This project has been moved to http://github.com/libgit2/ribbit
+Thanks!
+Scott
View
107 Rakefile
@@ -1,107 +0,0 @@
-# stolen largely from defunkt/mustache
-require 'rake/testtask'
-require 'rake/rdoctask'
-require 'rake/extensiontask'
-
-Rake::ExtensionTask.new('ribbit')
-
-#
-# Helpers
-#
-
-def command?(command)
- system("type #{command} > /dev/null")
-end
-
-
-#
-# Tests
-#
-
-task :default => :test
-
-if command? :turn
- desc "Run tests"
- task :test do
- suffix = "-n #{ENV['TEST']}" if ENV['TEST']
- sh "turn test/*.rb #{suffix}"
- end
-else
- Rake::TestTask.new do |t|
- t.libs << 'lib'
- t.pattern = 'test/**/*_test.rb'
- t.verbose = false
- end
-end
-
-if command? :kicker
- desc "Launch Kicker (like autotest)"
- task :kicker do
- puts "Kicking... (ctrl+c to cancel)"
- exec "kicker -e rake test lib examples"
- end
-end
-
-
-#
-# Ron
-#
-
-if command? :ronn
- desc "Show the manual"
- task :man => "man:build" do
- exec "man man/mustache.1"
- end
-
- desc "Build the manual"
- task "man:build" do
- sh "ronn -br5 --organization=SCHACON --manual='Ribbit Manual' man/*.ron"
- end
-end
-
-
-#
-# Gems
-#
-
-begin
- require 'mg'
- MG.new("ribbit.gemspec")
-
- desc "Push a new version to Gemcutter and publish docs."
- task :publish => "gem:publish" do
- require File.dirname(__FILE__) + '/lib/mustache/version'
-
- system "git tag v#{Ribbit::Version}"
- sh "git push origin master --tags"
- sh "git clean -fd"
- exec "rake pages"
- end
-rescue LoadError
- warn "mg not available."
- warn "Install it with: gem i mg"
-end
-
-#
-# Documentation
-#
-
-desc "Publish to GitHub Pages"
-task :pages => [ "man:build" ] do
- Dir['man/*.html'].each do |f|
- cp f, File.basename(f).sub('.html', '.newhtml')
- end
-
- `git commit -am 'generated manual'`
- `git checkout site`
-
- Dir['*.newhtml'].each do |f|
- mv f, f.sub('.newhtml', '.html')
- end
-
- `git add .`
- `git commit -m updated`
- `git push site site:master`
- `git checkout master`
- puts :done
-end
View
@@ -1,64 +0,0 @@
-require 'benchmark'
-require 'rubygems'
-require 'grit'
-require 'pp'
-
-dir = File.dirname(File.expand_path(__FILE__))
-$LOAD_PATH.unshift dir + '/lib'
-require 'ribbit'
-
-n = 5000
-
-sha = "8496071c1b46c854b31185ea97743be6a8774479"
-psha = "41bc8c69075bbdb46c5c6f0566cc8cc5b46e8bd9"
-raw = Ribbit::Lib.hex_to_raw(sha)
-
-repo = File.dirname(File.expand_path(__FILE__)) + "/test/fixtures/testrepo.git"
-
-psha = "f7c7e7614af3d26a05aeb324528b6d42076c4e6d"
-sha = "78af21ad7104d6f64b46cbc87f6ca944b8f412da"
-repo = "/Users/schacon/projects/github/.git"
-
-Benchmark.bm do |x|
-
- @grit = Grit::Repo.new(repo).git
- @ribbit = Ribbit::Odb.new(repo + '/objects')
-
- x.report("Grit object_exists? loose ") do
- @grit = Grit::Repo.new(repo).git
- 1.upto(n) { @grit.object_exists?(sha) }
- end
- x.report("Grit object_exists? packed") do
- @grit = Grit::Repo.new(repo).git
- 1.upto(n) { @grit.object_exists?(psha) }
- end
- x.report("Ribbit object_exists? loose ") do
- @ribbit = Ribbit::Odb.new(repo + '/objects')
- 1.upto(n) { @ribbit.exists(sha) }
- end
- x.report("Ribbit object_exists? packed") do
- @ribbit = Ribbit::Odb.new(repo + '/objects')
- 1.upto(n) { @ribbit.exists(psha) }
- end
-
-end
-
-exit
-
-n = 50000
-
-Benchmark.bm do |x|
-
- x.report("Ribbit Hex2Raw:") do
- 1.upto(n) { Ribbit::Lib.hex_to_raw(sha) }
- end
- x.report("Ruby Hex2Raw :") do
- 1.upto(n) { [sha].pack("H*") }
- end
- x.report("Ribbit Raw2Hex:") do
- 1.upto(n) { Ribbit::Lib.raw_to_hex(raw) }
- end
- x.report("Ruby Raw2Hex :") do
- 1.upto(n) { raw.unpack("H*")[0] }
- end
-end
View
@@ -1,9 +0,0 @@
-require 'mkmf'
-
-dir_config("ribbit")
-
-have_library("git2")
-have_library('z')
-
-create_makefile("ribbit")
-
Oops, something went wrong.

0 comments on commit ef2f2c0

Please sign in to comment.