Permalink
Browse files

Gemfile and dynamic gemspec

  • Loading branch information...
1 parent 60fadf0 commit 6064927ab47ca46d8f7383ce4704b18d73f0ff61 @spikex committed Mar 9, 2011
Showing with 37 additions and 109 deletions.
  1. +2 −0 .gitignore
  2. +4 −0 Gemfile
  3. +7 −16 Rakefile
  4. +1 −1 lib/strongbox.rb
  5. +23 −92 strongbox.gemspec
View
@@ -1,3 +1,5 @@
test/debug.log
doc
/strongbox-*.gem
+.bundle
+Gemfile.lock
View
@@ -0,0 +1,4 @@
+source "http://rubygems.org"
+
+# Specify your gem's dependencies in x.gemspec
+gemspec
View
@@ -24,22 +24,13 @@ Rake::RDocTask.new(:rdoc) do |rdoc|
rdoc.rdoc_files.include('lib/**/*.rb')
end
-spec = Gem::Specification.new do |s|
- s.name = "strongbox"
- s.version = Strongbox::VERSION
- s.summary = "Secures ActiveRecord fields with public key encryption."
- s.authors = ["Spike Ilacqua"]
- s.email = "spike@stuff-things.net"
- s.homepage = "http://stuff-things.net/strongbox"
- s.files = FileList["[A-Z]*", "init.rb", "{lib,rails}/**/*"]
- s.add_runtime_dependency 'activerecord'
- s.add_development_dependency 'thoughtbot-shoulda'
- s.add_development_dependency 'sqlite3'
-end
-
desc "Generate a gemspec file for GitHub"
task :gemspec do
- File.open("#{spec.name}.gemspec", 'w') do |f|
- f.write spec.to_yaml
- end
+ $spec = eval(File.read('strongbox.gemspec'))
+ $spec.validate
+end
+
+desc "Build the gem"
+task :build => :gemspec do
+ Gem::Builder.new($spec).build
end
View
@@ -5,7 +5,7 @@
module Strongbox
- VERSION = "0.4.2"
+ VERSION = "0.4.4"
RSA_PKCS1_PADDING = OpenSSL::PKey::RSA::PKCS1_PADDING
RSA_SSLV23_PADDING = OpenSSL::PKey::RSA::SSLV23_PADDING
View
@@ -1,92 +1,23 @@
---- !ruby/object:Gem::Specification
-name: strongbox
-version: !ruby/object:Gem::Version
- version: 0.4.2
-platform: ruby
-authors:
-- Spike Ilacqua
-autorequire:
-bindir: bin
-cert_chain: []
-
-date: 2011-01-17 00:00:00 -07:00
-default_executable:
-dependencies:
-- !ruby/object:Gem::Dependency
- name: activerecord
- type: :runtime
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-- !ruby/object:Gem::Dependency
- name: thoughtbot-shoulda
- type: :development
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-- !ruby/object:Gem::Dependency
- name: sqlite3
- type: :development
- version_requirement:
- version_requirements: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-description:
-email: spike@stuff-things.net
-executables: []
-
-extensions: []
-
-extra_rdoc_files: []
-
-files:
-- LICENSE
-- Rakefile
-- README.html
-- README.textile
-- init.rb
-- lib/strongbox
-- lib/strongbox/lock.rb
-- lib/strongbox.rb
-- rails/init.rb
-has_rdoc: true
-homepage: http://stuff-things.net/strongbox
-licenses: []
-
-post_install_message:
-rdoc_options: []
-
-require_paths:
-- lib
-required_ruby_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-required_rubygems_version: !ruby/object:Gem::Requirement
- requirements:
- - - ">="
- - !ruby/object:Gem::Version
- version: "0"
- version:
-requirements: []
-
-rubyforge_project:
-rubygems_version: 1.3.5
-signing_key:
-specification_version: 3
-summary: Secures ActiveRecord fields with public key encryption.
-test_files: []
-
+lib = File.expand_path('../lib/', __FILE__)
+$:.unshift lib unless $:.include?(lib)
+require 'strongbox'
+
+Gem::Specification.new do |s|
+ s.name = "strongbox"
+ s.version = Strongbox::VERSION
+ s.summary = "Secures ActiveRecord fields with public key encryption."
+ s.authors = ["Spike Ilacqua"]
+ s.email = "spike@stuff-things.net"
+ s.description = <<-EOF
+ Strongbox provides Public Key Encryption for ActiveRecord. By using a
+ public key sensitive information can be encrypted and stored automatically.
+ Once stored a password is required to access the information. dependencies
+ are specified in standard Ruby syntax.
+ EOF
+ s.homepage = "http://stuff-things.net/strongbox"
+ s.files = `git ls-files`.split("\n")
+ s.test_files = `git ls-files -- test/*`.split("\n")
+ s.add_runtime_dependency 'activerecord'
+ s.add_development_dependency 'thoughtbot-shoulda'
+ s.add_development_dependency 'sqlite3'
+end

0 comments on commit 6064927

Please sign in to comment.