Permalink
Browse files

gemified

  • Loading branch information...
1 parent 4bf602c commit 976dc77d521c2ca22c683899fcb8e214f1549cc4 @nofxx committed Dec 10, 2008
View
@@ -1,14 +0,0 @@
-# #
-# require 'autotest/html_report'
-# require 'autotest/kdenotify'
-# require 'autotest/pretty'
-# require 'autotest/snarl'
-require 'autotest/timestamp'
-require 'autotest/redgreen'
-require 'autotest/menu'
-
-module Autotest::Growl
- Autotest.add_hook :initialize do |at|
- %w{.hg .git .DS_store .log}.each {|exception| at.add_exception(exception)}
- end
-end
View
@@ -0,0 +1,6 @@
+=== 1.0.0 / 2008-12-10
+
+* 1 major enhancement
+
+ * Birthday!
+
View
@@ -0,0 +1,36 @@
+History.txt
+MIT-LICENSE
+Manifest.txt
+README.markdown
+Rakefile
+init.rb
+install.rb
+lib/postgis_adapter.rb
+lib/postgis_adapter/acts_as_geom.rb
+lib/postgis_adapter/common_spatial_adapter.rb
+lib/postgis_functions.rb
+lib/postgis_functions/bbox.rb
+lib/postgis_functions/class.rb
+lib/postgis_functions/common.rb
+lib/postgis_functions/linestring.rb
+lib/postgis_functions/point.rb
+lib/postgis_functions/polygon.rb
+postgis_adapter.gemspec
+rails/init.rb
+script/console
+script/destroy
+script/generate
+spec/acts_as_geom_spec.rb
+spec/common_spatial_adapter_spec.rb
+spec/db/database_postgis.yml
+spec/db/models_postgis.rb
+spec/db/schema_postgis.rb
+spec/postgis_adapter_spec.rb
+spec/postgis_functions/bbox_spec.rb
+spec/postgis_functions/linestring_spec.rb
+spec/postgis_functions/point_spec.rb
+spec/postgis_functions/polygon_spec.rb
+spec/postgis_functions_spec.rb
+spec/spec.opts
+spec/spec_helper.rb
+uninstall.rb
View
@@ -3,6 +3,39 @@ $:.unshift(File.join(File.dirname(__FILE__), 'lib'))
require 'rake'
require 'spec/rake/spectask'
require 'rake/rdoctask'
+require 'active_record'
+require 'active_record/connection_adapters/postgresql_adapter'
+%w[rubygems rake rake/clean fileutils newgem rubigen].each { |f| require f }
+require File.dirname(__FILE__) + '/lib/postgis_adapter'
+
+# Generate all the Rake tasks
+# Run 'rake -T' to see list of generated tasks (from gem root directory)PostgisAdapter::VERSION
+$hoe = Hoe.new('postgis_adapter', PostgisAdapter::VERSION) do |p|
+ p.developer('Marcos Piccinini', 'x@nofxx.com')
+ p.summary = "Postgis Adapter for Activer Record"
+ p.description = "Postgis Adapter for Activer Record"
+ p.url = "http://github.com/nofxx/postgis_adapter"
+ p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n")
+# p.post_install_message = 'PostInstall.txt' # TODO remove if post-install message not required
+ p.rubyforge_name = "postgis_adapter" # TODO this is default value
+ p.extra_deps = [
+ ['activerecord','>= 2.0.2'],
+ ]
+ p.extra_dev_deps = [
+ ['newgem', ">= #{::Newgem::VERSION}"]
+ ]
+
+ p.clean_globs |= %w[**/.DS_Store tmp *.log]
+ path = (p.rubyforge_name == p.name) ? p.rubyforge_name : "\#{p.rubyforge_name}/\#{p.name}"
+ p.remote_rdoc_dir = File.join(path.gsub(/^#{p.rubyforge_name}\/?/,''), 'rdoc')
+ p.rsync_args = '-av --delete --ignore-errors'
+end
+
+require 'newgem/tasks' # load /tasks/*.rake
+Dir['tasks/**/*.rake'].each { |t| load t }
+
+# TODO - want other tests/tasks run by default? Add them to the list
+# task :default => [:spec, :features]
desc 'Default: run specs.'
@@ -38,7 +71,7 @@ end
desc "Generate the documentation"
Rake::RDocTask::new do |rdoc|
- rdoc.rdoc_dir = 'rdoc/'
+ rdoc.rdoc_dir = 'doc/'
rdoc.title = "PostGIS Adapter for Rails Documentation"
rdoc.options << '--line-numbers' << '--inline-source'
rdoc.rdoc_files.include('README.markdown')
View
@@ -1,8 +1 @@
-class SpatialAdapterNotCompatibleError < StandardError
-end
-
-unless ActiveRecord::Base.connection.adapter_name == 'PostgreSQL'
- raise SpatialAdapterNotCompatibleError.
- new("Only PostgreSQL with PostGIS is supported by the postgis adapter plugin.")
-end
-require 'postgis_adapter'
+require File.dirname(__FILE__) + "/rails/init"
View
@@ -6,21 +6,21 @@
#
#require 'active_record'
require 'geo_ruby'
-require 'common_spatial_adapter'
+require 'postgis_adapter/common_spatial_adapter'
require 'postgis_functions'
require 'postgis_functions/common'
require 'postgis_functions/class'
require 'postgis_functions/point'
require 'postgis_functions/linestring'
require 'postgis_functions/polygon'
require 'postgis_functions/bbox'
-require 'acts_as_geom'
+require 'postgis_adapter/acts_as_geom'
include GeoRuby::SimpleFeatures
include SpatialAdapter
module PostgisAdapter
- VERSION = '0.0.8'
+ VERSION = '0.1.1'
end
#tables to ignore in migration : relative to PostGIS management of geometric columns
File renamed without changes.
View
@@ -0,0 +1,40 @@
+# -*- encoding: utf-8 -*-
+
+Gem::Specification.new do |s|
+ s.name = %q{postgis_adapter}
+ s.version = "0.1.1"
+
+ s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
+ s.authors = ["Marcos Piccinini"]
+ s.date = %q{2008-12-10}
+ s.description = %q{Postgis Adapter for Activer Record}
+ s.email = ["x@nofxx.com"]
+ s.extra_rdoc_files = ["History.txt", "Manifest.txt"]
+ s.files = ["History.txt", "MIT-LICENSE", "Manifest.txt", "README.markdown", "Rakefile", "init.rb", "install.rb", "lib/postgis_adapter.rb", "lib/postgis_adapter/acts_as_geom.rb", "lib/postgis_adapter/common_spatial_adapter.rb", "lib/postgis_functions.rb", "lib/postgis_functions/bbox.rb", "lib/postgis_functions/class.rb", "lib/postgis_functions/common.rb", "lib/postgis_functions/linestring.rb", "lib/postgis_functions/point.rb", "lib/postgis_functions/polygon.rb", "postgis_adapter.gemspec", "rails/init.rb", "script/console", "script/destroy", "script/generate", "spec/acts_as_geom_spec.rb", "spec/common_spatial_adapter_spec.rb", "spec/db/database_postgis.yml", "spec/db/models_postgis.rb", "spec/db/schema_postgis.rb", "spec/postgis_adapter_spec.rb", "spec/postgis_functions/bbox_spec.rb", "spec/postgis_functions/linestring_spec.rb", "spec/postgis_functions/point_spec.rb", "spec/postgis_functions/polygon_spec.rb", "spec/postgis_functions_spec.rb", "spec/spec.opts", "spec/spec_helper.rb", "uninstall.rb"]
+ s.has_rdoc = true
+ s.homepage = %q{http://github.com/nofxx/postgis_adapter}
+ s.rdoc_options = ["--main", "README.markdown"]
+ s.require_paths = ["lib"]
+ s.rubyforge_project = %q{postgis_adapter}
+ s.rubygems_version = %q{1.3.1}
+ s.summary = %q{Postgis Adapter for Activer Record}
+
+ if s.respond_to? :specification_version then
+ current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
+ s.specification_version = 2
+
+ if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
+ s.add_runtime_dependency(%q<activerecord>, [">= 2.0.2"])
+ s.add_development_dependency(%q<newgem>, [">= 1.1.0"])
+ s.add_development_dependency(%q<hoe>, [">= 1.8.0"])
+ else
+ s.add_dependency(%q<activerecord>, [">= 2.0.2"])
+ s.add_dependency(%q<newgem>, [">= 1.1.0"])
+ s.add_dependency(%q<hoe>, [">= 1.8.0"])
+ end
+ else
+ s.add_dependency(%q<activerecord>, [">= 2.0.2"])
+ s.add_dependency(%q<newgem>, [">= 1.1.0"])
+ s.add_dependency(%q<hoe>, [">= 1.8.0"])
+ end
+end
View
@@ -0,0 +1,8 @@
+class SpatialAdapterNotCompatibleError < StandardError
+end
+
+unless ActiveRecord::Base.connection.adapter_name == 'PostgreSQL'
+ raise SpatialAdapterNotCompatibleError.
+ new("Only PostgreSQL with PostGIS is supported by the postgis adapter plugin.")
+end
+require 'postgis_adapter'
View
@@ -0,0 +1,10 @@
+#!/usr/bin/env ruby
+# File: script/console
+irb = RUBY_PLATFORM =~ /(:?mswin|mingw)/ ? 'irb.bat' : 'irb'
+
+libs = " -r irb/completion"
+# Perhaps use a console_lib to store any extra methods I may want available in the cosole
+# libs << " -r #{File.dirname(__FILE__) + '/../lib/console_lib/console_logger.rb'}"
+libs << " -r #{File.dirname(__FILE__) + '/../lib/postgis_adapter.rb'}"
+puts "Loading postgis_adapter gem"
+exec "#{irb} #{libs} --simple-prompt"
View
@@ -0,0 +1,14 @@
+#!/usr/bin/env ruby
+APP_ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..'))
+
+begin
+ require 'rubigen'
+rescue LoadError
+ require 'rubygems'
+ require 'rubigen'
+end
+require 'rubigen/scripts/destroy'
+
+ARGV.shift if ['--help', '-h'].include?(ARGV[0])
+RubiGen::Base.use_component_sources! [:rubygems, :newgem, :newgem_theme, :test_unit]
+RubiGen::Scripts::Destroy.new.run(ARGV)
View
@@ -0,0 +1,14 @@
+#!/usr/bin/env ruby
+APP_ROOT = File.expand_path(File.join(File.dirname(__FILE__), '..'))
+
+begin
+ require 'rubigen'
+rescue LoadError
+ require 'rubygems'
+ require 'rubigen'
+end
+require 'rubigen/scripts/generate'
+
+ARGV.shift if ['--help', '-h'].include?(ARGV[0])
+RubiGen::Base.use_component_sources! [:rubygems, :newgem, :newgem_theme, :test_unit]
+RubiGen::Scripts::Generate.new.run(ARGV)

0 comments on commit 976dc77

Please sign in to comment.