Permalink
Browse files

Move the meta driver bson into its own repository

  • Loading branch information...
1 parent 30145b9 commit 7eee928b1c011df7860629cfd84fb43ac29252ac @durran durran committed Apr 12, 2013
Showing with 96 additions and 7,864 deletions.
  1. +1 −1 .gitignore
  2. +3 −0 .rspec
  3. +1 −0 .ruby-gemset
  4. +1 −0 .ruby-version
  5. 0 {ruby → }/CHANGELOG.md
  6. +17 −0 Gemfile
  7. 0 features/bson/object_id.feature → LICENSE.md
  8. 0 {ruby → }/README.md
  9. +0 −11 README.rst
  10. +69 −0 Rakefile
  11. +3 −3 {ruby → }/bson.gemspec
  12. +0 −83 docs/bin/additional_directives.py
  13. +0 −23 docs/bin/copy-if-needed
  14. +0 −17 docs/bin/create-link
  15. +0 −215 docs/bin/makefile_builder.py
  16. +0 −42 docs/bin/mongodb_docs_meta.py
  17. +0 −321 docs/bin/mongodb_domain.py
  18. +0 −18 docs/bin/published-build-check
  19. +0 −2,203 docs/bin/sitemap_gen.py
  20. +0 −1 docs/bin/sphinx_conf.py
  21. +0 −229 docs/bin/table_builder.py
  22. +0 −1 docs/build
  23. +0 −23 docs/conf-sitemap.xml
  24. +0 −147 docs/conf.py
  25. +0 −358 docs/makefile
  26. +0 −31 docs/source/.static/10gen-gpg-key.asc
  27. BIN docs/source/.static/logo-mongodb.png
  28. +0 −23 docs/source/about.txt
  29. +0 −14 docs/source/contents.txt
  30. +0 −1 docs/source/features
  31. +0 −1 docs/source/implementation-ruby
  32. +0 −6 docs/source/includes/note-legacy.rst
  33. +0 −4 docs/source/includes/warning-draft-note.rst
  34. +0 −52 docs/source/index.txt
  35. +0 −18 docs/source/legacy.txt
  36. +0 −187 docs/source/legacy/bson.txt
  37. +0 −72 docs/source/legacy/connect-driver-to-replica-set.txt
  38. +0 −26 docs/source/legacy/conventions-for-mongodb-drivers.txt
  39. +0 −21 docs/source/legacy/driver-test-tools.txt
  40. +0 −52 docs/source/legacy/error-handling-in-drivers.txt
  41. +0 −87 docs/source/legacy/feature-checklist-for-mongodb-drivers.txt
  42. +0 −10 docs/source/legacy/gridfs-specification.txt
  43. +0 −172 docs/source/legacy/implement-authentication-in-driver.txt
  44. +0 −235 docs/source/legacy/mongodb-driver-requirements.txt
  45. +0 −534 docs/source/legacy/mongodb-wire-protocol.txt
  46. +0 −130 docs/source/legacy/notes-on-pooling-for-mongodb-drivers.txt
  47. +0 −17 docs/source/legacy/spec-notes-suggestions-for-mongodb-drivers.txt
  48. +0 −9 docs/source/specification.txt
  49. +0 −26 docs/source/specification/bson.txt
  50. +0 −14 docs/source/tutorial.txt
  51. +0 −24 docs/themes/epub_mongodb/epub-cover.html
  52. +0 −19 docs/themes/epub_mongodb/layout.html
  53. +0 −465 docs/themes/epub_mongodb/static/epub.css
  54. +0 −4 docs/themes/epub_mongodb/theme.conf
  55. +0 −5 docs/themes/meta-driver/.htaccess
  56. +0 −56 docs/themes/meta-driver/index.html
  57. +0 −14 docs/themes/meta-driver/osd.xml
  58. +0 −23 docs/themes/mongodb/analytics.html
  59. +0 −9 docs/themes/mongodb/formats.html
  60. +0 −9 docs/themes/mongodb/globaltoc.html
  61. +0 −11 docs/themes/mongodb/intrasites.html
  62. +0 −15 docs/themes/mongodb/jiracollector.html
  63. +0 −199 docs/themes/mongodb/layout.html
  64. +0 −22 docs/themes/mongodb/linktags.html
  65. +0 −10 docs/themes/mongodb/localtoc.html
  66. +0 −13 docs/themes/mongodb/page.html
  67. +0 −7 docs/themes/mongodb/pagenav.html
  68. +0 −58 docs/themes/mongodb/search.html
  69. +0 −16 docs/themes/mongodb/sourcelink.html
  70. +0 −833 docs/themes/mongodb/static/mongodb-docs.css_t
  71. +0 −46 docs/themes/mongodb/static/reset.css
  72. +0 −15 docs/themes/mongodb/theme.conf
  73. +0 −22 docs/themes/mongodb/translations.html
  74. +0 −41 docs/themes/mongodb/wikisidebar.html
  75. 0 {ruby → }/ext/bson/extconf.rb
  76. 0 {ruby → }/ext/bson/native.c
  77. +0 −103 features/bson/serialize.feature
  78. +0 −45 features/bson/step_definitons/bson_steps.rb
  79. +0 −137 features/bson/step_definitons/support/transforms.rb
  80. +0 −2 features/support/env.rb
  81. 0 {ruby → }/lib/bson.rb
  82. 0 {ruby → }/lib/bson/array.rb
  83. 0 {ruby → }/lib/bson/binary.rb
  84. 0 {ruby → }/lib/bson/boolean.rb
  85. 0 {ruby → }/lib/bson/code.rb
  86. 0 {ruby → }/lib/bson/code_with_scope.rb
  87. 0 {ruby → }/lib/bson/document.rb
  88. 0 {ruby → }/lib/bson/encodable.rb
  89. 0 {ruby → }/lib/bson/false_class.rb
  90. 0 {ruby → }/lib/bson/float.rb
  91. 0 {ruby → }/lib/bson/hash.rb
  92. 0 {ruby → }/lib/bson/int32.rb
  93. 0 {ruby → }/lib/bson/int64.rb
  94. 0 {ruby → }/lib/bson/integer.rb
  95. 0 {ruby → }/lib/bson/json.rb
  96. 0 {ruby → }/lib/bson/max_key.rb
  97. 0 {ruby → }/lib/bson/min_key.rb
  98. 0 {ruby → }/lib/bson/nil_class.rb
  99. 0 {ruby → }/lib/bson/object_id.rb
  100. 0 {ruby → }/lib/bson/regexp.rb
  101. 0 {ruby → }/lib/bson/registry.rb
  102. 0 {ruby → }/lib/bson/string.rb
  103. 0 {ruby → }/lib/bson/symbol.rb
  104. 0 {ruby → }/lib/bson/time.rb
  105. 0 {ruby → }/lib/bson/timestamp.rb
  106. 0 {ruby → }/lib/bson/true_class.rb
  107. 0 {ruby → }/lib/bson/undefined.rb
  108. 0 {ruby → }/lib/bson/version.rb
  109. +0 −10 makefile
  110. 0 {ruby → }/perf/bench.rb
  111. 0 {ruby → }/perf/bench_test.rb
  112. 0 ruby/LICENSE
  113. +0 −10 ruby/lib/mongo.rb
  114. +0 −4 ruby/lib/mongo/client.rb
  115. +0 −4 ruby/lib/mongo/cluster.rb
  116. +0 −4 ruby/lib/mongo/collection.rb
  117. +0 −4 ruby/lib/mongo/cursor.rb
  118. +0 −4 ruby/lib/mongo/database.rb
  119. 0 ruby/lib/mongo/errors.rb
  120. 0 ruby/lib/mongo/index.rb
  121. +0 −4 ruby/lib/mongo/logging.rb
  122. +0 −4 ruby/lib/mongo/node.rb
  123. +0 −4 ruby/lib/mongo/pool.rb
  124. +0 −12 ruby/lib/mongo/protocol.rb
  125. +0 −9 ruby/lib/mongo/protocol/delete.rb
  126. +0 −9 ruby/lib/mongo/protocol/get_more.rb
  127. +0 −18 ruby/lib/mongo/protocol/insert.rb
  128. +0 −9 ruby/lib/mongo/protocol/kill_cursors.rb
  129. +0 −39 ruby/lib/mongo/protocol/message.rb
  130. +0 −9 ruby/lib/mongo/protocol/query.rb
  131. +0 −9 ruby/lib/mongo/protocol/reply.rb
  132. +0 −9 ruby/lib/mongo/protocol/update.rb
  133. +0 −6 ruby/lib/mongo/sockets/ssl.rb
  134. +0 −6 ruby/lib/mongo/sockets/tcp.rb
  135. +0 −6 ruby/lib/mongo/sockets/unix.rb
  136. +0 −4 ruby/lib/mongo/uri.rb
  137. +0 −4 ruby/lib/mongo/version.rb
  138. +1 −0 ruby/tmp/rspec_guard_result
  139. 0 {ruby → }/spec/bson/array_spec.rb
  140. 0 {ruby → }/spec/bson/binary_spec.rb
  141. 0 {ruby → }/spec/bson/boolean_spec.rb
  142. 0 {ruby → }/spec/bson/code_spec.rb
  143. 0 {ruby → }/spec/bson/code_with_scope_spec.rb
  144. 0 {ruby → }/spec/bson/document_spec.rb
  145. 0 {ruby → }/spec/bson/false_class_spec.rb
  146. 0 {ruby → }/spec/bson/float_spec.rb
  147. 0 {ruby → }/spec/bson/hash_spec.rb
  148. 0 {ruby → }/spec/bson/int32_spec.rb
  149. 0 {ruby → }/spec/bson/int64_spec.rb
  150. 0 {ruby → }/spec/bson/integer_spec.rb
  151. 0 {ruby → }/spec/bson/json_spec.rb
  152. 0 {ruby → }/spec/bson/max_key_spec.rb
  153. 0 {ruby → }/spec/bson/min_key_spec.rb
  154. 0 {ruby → }/spec/bson/nil_class_spec.rb
  155. 0 {ruby → }/spec/bson/object_id_spec.rb
  156. 0 {ruby → }/spec/bson/regexp_spec.rb
  157. 0 {ruby → }/spec/bson/registry_spec.rb
  158. 0 {ruby → }/spec/bson/string_spec.rb
  159. 0 {ruby → }/spec/bson/symbol_spec.rb
  160. 0 {ruby → }/spec/bson/time_spec.rb
  161. 0 {ruby → }/spec/bson/timestamp_spec.rb
  162. 0 {ruby → }/spec/bson/true_class_spec.rb
  163. 0 {ruby → }/spec/bson/undefined_spec.rb
  164. 0 {ruby → }/spec/bson_spec.rb
  165. 0 {ruby → }/spec/spec_helper.rb
  166. 0 {ruby → }/spec/support/shared_examples.rb
  167. +0 −2 travis.sh
View
@@ -9,7 +9,7 @@ build/*
*.bak
.DS_Store
.rvmrc
-ruby/tmp/*
+tmp/*
*.o
*.bundle
Makefile
View
3 .rspec
@@ -0,0 +1,3 @@
+--color
+--format documentation
+--tty
View
@@ -0,0 +1 @@
+bson
View
@@ -0,0 +1 @@
+ruby-2.0.0-p0
File renamed without changes.
View
17 Gemfile
@@ -0,0 +1,17 @@
+source "https://rubygems.org"
+
+gem "rake"
+
+group :development, :test do
+ gem "cucumber"
+ gem "rspec"
+
+ unless ENV["CI"]
+ gem "guard-rspec"
+ gem "pry"
+ gem "rb-fsevent"
+ gem "terminal-notifier-guard"
+ gem "json"
+ gem "ruby-prof", :platforms => :mri
+ end
+end
File renamed without changes.
File renamed without changes.
View
@@ -1,11 +0,0 @@
-===========================
-MongoDB Meta Driver Project
-===========================
-
-The MongoDB Meta Driver is an attempt to formally specify the client
-library interface for MongoDB. Eventually the documents and this
-specification will enhance and replace the current `MongoDB
-driver writing tutorial <http://www.mongodb.org/display/DOCS/Writing+Drivers+and+Tools>`_.
-
-In the mean time consider *all* content in this repository incomplete,
-draft, and non-final.
View
@@ -0,0 +1,69 @@
+require "bundler"
+Bundler.setup
+
+$LOAD_PATH.unshift(File.expand_path("../lib", __FILE__))
+
+require "rake"
+require "cucumber/rake/task"
+require "rspec/core/rake_task"
+
+require "bson/version"
+
+if RUBY_VERSION < "1.9"
+ require "perf/bench"
+else
+ require_relative "perf/bench"
+end
+
+RSpec::Core::RakeTask.new(:spec)
+RSpec::Core::RakeTask.new(:rspec)
+
+Cucumber::Rake::Task.new do |t|
+ t.cucumber_opts = %w{--format pretty}
+end
+
+def extension
+ RUBY_PLATFORM =~ /darwin/ ? "bundle" : "so"
+end
+
+def compile!
+ puts "Compiling native extensions..."
+ Dir.chdir(Pathname(__FILE__).dirname + "ext/bson") do
+ `bundle exec ruby extconf.rb`
+ `make`
+ `cp native.#{extension} ../../lib/bson`
+ end
+end
+
+task :compile do
+ compile!
+end
+
+task :clean do
+ puts "Cleaning out native extensions..."
+ begin
+ Dir.chdir(Pathname(__FILE__).dirname + "lib/bson") do
+ `rm native.#{extension}`
+ `rm native.o`
+ end
+ rescue Exception => e
+ puts e.message
+ end
+end
+
+namespace :benchmark do
+
+ task :ruby => :clean do
+ puts "Benchmarking pure Ruby..."
+ require "bson"
+ benchmark!
+ end
+
+ task :c => :compile do
+ puts "Benchmarking with C extensions..."
+ require "bson"
+ benchmark!
+ end
+end
+
+task :default => [ :clean, :spec, :compile, :rspec ]
@@ -15,10 +15,10 @@ Gem::Specification.new do |s|
s.description = "A full featured BSON specification implementation, in Ruby"
s.license = "Apache"
- s.required_ruby_version = ">= 1.9.3"
+ s.required_ruby_version = ">= 1.8.7"
s.required_rubygems_version = ">= 1.3.6"
s.rubyforge_project = "bson"
- s.files = Dir.glob("lib/**/*") + %w(CHANGELOG.md LICENSE README.md Rakefile)
- s.require_path = 'lib'
+ s.files = Dir.glob("lib/**/*") + %w(CHANGELOG.md LICENSE.md README.md Rakefile)
+ s.require_path = "lib"
end
@@ -1,83 +0,0 @@
-from docutils.parsers.rst import Directive, directives
-from docutils import nodes
-from sphinx.locale import _
-from sphinx.util.compat import Directive, make_admonition
-from sphinx import addnodes
-
-class MongoDBNode(Directive):
- """
- An custom admonition for the MongoDB Manual.
- """
- has_content = True
- required_arguments = 0
- optional_arguments = 1
- final_argument_whitespace = True
- option_spec = {}
- is_seealso = False
- is_related = False
-
- def run(self):
- if self.is_seealso:
- ret = make_admonition(addnodes.seealso, self.name, [_('See')], self.options,
- self.content, self.lineno, self.content_offset, self.block_text,
- self.state, self.state_machine)
- elif self.is_related:
- ret = make_admonition(addnodes.seealso, self.name, [_('Related')], self.options,
- self.content, self.lineno, self.content_offset, self.block_text,
- self.state, self.state_machine)
- else:
- ret = make_admonition(optional_node, self.name, self.directive_name, self.options,
- self.content, self.lineno, self.content_offset,
- self.block_text, self.state, self.state_machine)
-
- if self.arguments:
- argnodes, msgs = self.state.inline_text(self.arguments[0],
- self.lineno)
- para = nodes.paragraph()
- para += argnodes
- para += msgs
- ret[0].insert(1, para)
- return ret
-
-def visit_mongodb_node(self, node):
- self.visit_admonition(node)
-
-def depart_mongodb_node(self, node):
- self.depart_admonition(node)
-
-def mongodb_add_node(app, type):
- app.add_node(type,
- html=(visit_mongodb_node, depart_mongodb_node),
- latex=(visit_mongodb_node, depart_mongodb_node),
- text=(visit_mongodb_node, depart_mongodb_node),
- man=(visit_mongodb_node, depart_mongodb_node),
- texinfo=(visit_mongodb_node, depart_mongodb_node))
-
-################################################################################
-
-class optional_node(nodes.Admonition, nodes.Element): pass
-
-class example_node(nodes.Admonition, nodes.Element): pass
-
-class Optional(MongoDBNode):
- directive_name = ["Optional"]
-
-class Example(MongoDBNode):
- directive_name = ["Example"]
-
-class See(MongoDBNode):
- is_seealso = True
- directive_name = ["See"]
-
-class Related(MongoDBNode):
- is_related = True
- directive_name = ["Related"]
-
-def setup(app):
- app.add_directive('optional', Optional)
- app.add_directive('see', See)
- app.add_directive('related', Related)
- app.add_directive('example', Example)
-
- mongodb_add_node(app, optional_node)
- mongodb_add_node(app, example_node)
View
@@ -1,23 +0,0 @@
-#!/bin/bash
-
-GENERATED_FILE=$1
-OUTPUT_FILE=$2
-
-if [ ! -f $GENERATED_FILE ]; then
- cp $OUTPUT_FILE $GENERATED_FILE || exit 1
- echo "[PDF]: created $GENERATED_FILE; rebuild needed"
- exit 0
-fi
-
-diff $GENERATED_FILE $OUTPUT_FILE >/dev/null
-FILE_CHANGED=$?
-
-if [ $FILE_CHANGED = 1 ]; then
- cp $OUTPUT_FILE $GENERATED_FILE || exit 1
- echo "[PDF]: changes require a rebuild"
- exit 0
-elif [ $FILE_CHANGED = 0 ]; then
- echo "[PDF]: no changes; no rebuild required"
- exit 0
-fi
-
View
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-link_target=$1
-link_name=$2
-output_dir=$3
-
-if [ -z $link_target ]; then
- exit 1
-elif [ -z $link_name ]; then
- exit 1
-elif [ -z $output_dir ]; then
- exit 1
-else
- ln -s -f $link_target $link_name
- mv $link_name $output_dir
- echo \[web\]: creating a link named \"$link_name\" targeting \"$link_target\"
-fi
Oops, something went wrong.

0 comments on commit 7eee928

Please sign in to comment.