From 6f0a5e2d84b654efd09363841b88c57a271abfa1 Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sat, 2 Feb 2013 08:16:55 -0800 Subject: [PATCH 1/6] Add bundler development dependency --- rails_admin.gemspec | 1 + 1 file changed, 1 insertion(+) diff --git a/rails_admin.gemspec b/rails_admin.gemspec index 7e7f75b760..109cdc40fc 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -16,6 +16,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'rack-pjax', '~> 0.6' spec.add_dependency 'rails', '~> 3.1' spec.add_dependency 'remotipart', '~> 1.0' + spec.add_development_dependency 'bundler', '~> 1.0' spec.authors = ["Erik Michaels-Ober", "Bogdan Gaza", "Petteri Kaapa", "Benoit Benezech"] spec.description = %q{RailsAdmin is a Rails engine that provides an easy-to-use interface for managing your data.} spec.email = ['sferik@gmail.com', 'bogdan@cadmio.org', 'petteri.kaapa@gmail.com'] From d160058643d7c8454a807778924a70c7733dc259 Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sat, 2 Feb 2013 09:15:27 -0800 Subject: [PATCH 2/6] require 'rails_admin/version' Because require hashes based on the string, not the expanded path of the file, it's important that we require the version file the same way that it will be required elsewhere to avoid constant warnings. --- rails_admin.gemspec | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/rails_admin.gemspec b/rails_admin.gemspec index 109cdc40fc..444a5e71d9 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -1,5 +1,7 @@ -# encoding: utf-8 -require File.expand_path('../lib/rails_admin/version', __FILE__) +# coding: utf-8 +lib = File.expand_path('../lib', __FILE__) +$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) +require 'rails_admin/version' Gem::Specification.new do |spec| # If you add a dependency, please maintain alphabetical order From a1cb1f0ff7b56ab49765d79f683f0f5394075fcf Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sun, 3 Feb 2013 01:52:11 -0800 Subject: [PATCH 3/6] Use of custom objects is not necessary here --- rails_admin.gemspec | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/rails_admin.gemspec b/rails_admin.gemspec index 444a5e71d9..6d14db0e71 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -5,19 +5,19 @@ require 'rails_admin/version' Gem::Specification.new do |spec| # If you add a dependency, please maintain alphabetical order - spec.add_dependency 'nested_form', '~> 0.3' - spec.add_dependency 'sass-rails', '~> 3.1' spec.add_dependency 'bootstrap-sass', '~> 2.2' - spec.add_dependency 'font-awesome-sass-rails', ['~> 3.0', '>= 3.0.0.1'] - spec.add_dependency 'jquery-ui-rails', '~> 3.0' spec.add_dependency 'builder', '~> 3.0' spec.add_dependency 'coffee-rails', '~> 3.1' + spec.add_dependency 'font-awesome-sass-rails', ['~> 3.0', '>= 3.0.0.1'] spec.add_dependency 'haml', '~> 3.1' spec.add_dependency 'jquery-rails', '~> 2.1' + spec.add_dependency 'jquery-ui-rails', '~> 3.0' spec.add_dependency 'kaminari', '~> 0.14' + spec.add_dependency 'nested_form', '~> 0.3' spec.add_dependency 'rack-pjax', '~> 0.6' spec.add_dependency 'rails', '~> 3.1' spec.add_dependency 'remotipart', '~> 1.0' + spec.add_dependency 'sass-rails', '~> 3.1' spec.add_development_dependency 'bundler', '~> 1.0' spec.authors = ["Erik Michaels-Ober", "Bogdan Gaza", "Petteri Kaapa", "Benoit Benezech"] spec.description = %q{RailsAdmin is a Rails engine that provides an easy-to-use interface for managing your data.} @@ -27,7 +27,7 @@ Gem::Specification.new do |spec| spec.homepage = 'https://github.com/sferik/rails_admin' spec.name = 'rails_admin' spec.require_paths = ['lib'] - spec.required_rubygems_version = Gem::Requirement.new('>= 1.3.6') + spec.required_rubygems_version = '>= 1.3.6' spec.summary = %q{Admin for Rails} spec.test_files = Dir['spec/**/*'] spec.version = RailsAdmin::Version From e09151c6758e9a6a62d28c3614021db92931381f Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sun, 3 Feb 2013 02:20:53 -0800 Subject: [PATCH 4/6] Add cryptographic signature --- public_cert.pem | 20 ++++++++++++++++++++ rails_admin.gemspec | 2 ++ 2 files changed, 22 insertions(+) create mode 100644 public_cert.pem diff --git a/public_cert.pem b/public_cert.pem new file mode 100644 index 0000000000..04e06401ee --- /dev/null +++ b/public_cert.pem @@ -0,0 +1,20 @@ +-----BEGIN CERTIFICATE----- +MIIDLjCCAhagAwIBAgIBADANBgkqhkiG9w0BAQUFADA9MQ8wDQYDVQQDDAZzZmVy +aWsxFTATBgoJkiaJk/IsZAEZFgVnbWFpbDETMBEGCgmSJomT8ixkARkWA2NvbTAe +Fw0xMzAyMDMxMDAyMjdaFw0xNDAyMDMxMDAyMjdaMD0xDzANBgNVBAMMBnNmZXJp +azEVMBMGCgmSJomT8ixkARkWBWdtYWlsMRMwEQYKCZImiZPyLGQBGRYDY29tMIIB +IjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAl0x5dx8uKxi7TkrIuyBUTJVB +v1o93nUB9j/y4M96gV2rYwAci1JPBseNd6Fybzjo3YGuHl7EQHuSHNaf1p2lxew/ +y60JXIJBBgPcDK/KCP4NUHofm0jfoYD+H5uNJfHCNq7/ZsTxOtE3Ra92s0BCMTpm +wBMMlWR5MtdEhIYuBO4XhnejYgH0L/7BL2lymntVnsr/agdQoojQCN1IQmsRJvrR +duZRO3tZvoIo1pBc4JEehDuqCeyBgPLOqMoKtQlold1TQs1kWUBK7KWMFEhKC/Kg +zyzKRHQo9yDYwOvYngoBLY+T/lwCT4dyssdhzRbfnxAhaKu4SAssIwaC01yVowID +AQABozkwNzAJBgNVHRMEAjAAMB0GA1UdDgQWBBS0ruDfRak5ci1OpDNX/ZdDEkIs +iTALBgNVHQ8EBAMCBLAwDQYJKoZIhvcNAQEFBQADggEBAHHSMs/MP0sOaLkEv4Jo +zvkm3qn5A6t0vaHx774cmejyMU+5wySxRezspL7ULh9NeuK2OhU+Oe3TpqrAg5TK +R8GQILnVu2FemGA6sAkPDlcPtgA6ieI19PZOF6HVLmc/ID/dP/NgZWWzEeqQKmcK +2+HM+SEEDhZkScYekw4ZOe164ZtZG816oAv5x0pGitSIkumUp7V8iEZ/6ehr7Y9e +XOg4eeun5L/JjmjARoW2kNdvkRD3c2EeSLqWvQRsBlypHfhs6JJuLlyZPGhU3R/v +Sf3lVKpBCWgRpGTvy45XVpB+59y33PJmEuQ1PTEOYvQyao9UKMAAaAN/7qWQtjl0 +hlw= +-----END CERTIFICATE----- diff --git a/rails_admin.gemspec b/rails_admin.gemspec index 6d14db0e71..f3e7c7a91e 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -20,6 +20,7 @@ Gem::Specification.new do |spec| spec.add_dependency 'sass-rails', '~> 3.1' spec.add_development_dependency 'bundler', '~> 1.0' spec.authors = ["Erik Michaels-Ober", "Bogdan Gaza", "Petteri Kaapa", "Benoit Benezech"] + spec.cert_chain = ['public_cert.pem'] spec.description = %q{RailsAdmin is a Rails engine that provides an easy-to-use interface for managing your data.} spec.email = ['sferik@gmail.com', 'bogdan@cadmio.org', 'petteri.kaapa@gmail.com'] spec.files = Dir['Gemfile', 'LICENSE.md', 'README.md', 'Rakefile', 'app/**/*', 'config/**/*', 'lib/**/*', 'public/**/*'] @@ -28,6 +29,7 @@ Gem::Specification.new do |spec| spec.name = 'rails_admin' spec.require_paths = ['lib'] spec.required_rubygems_version = '>= 1.3.6' + spec.signing_key = '/Users/sferik/.gem/private_key.pem' spec.summary = %q{Admin for Rails} spec.test_files = Dir['spec/**/*'] spec.version = RailsAdmin::Version From 9d83dbcd87cfface6db7abf5ca4955554bd40f6c Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sun, 3 Feb 2013 10:58:17 -0800 Subject: [PATCH 5/6] Ignore signing key when not building Closes #1503. --- rails_admin.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rails_admin.gemspec b/rails_admin.gemspec index f3e7c7a91e..a4b8bf67fa 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.name = 'rails_admin' spec.require_paths = ['lib'] spec.required_rubygems_version = '>= 1.3.6' - spec.signing_key = '/Users/sferik/.gem/private_key.pem' + spec.signing_key = '/Users/sferik/.gem/private_key.pem' if $0 =~ /gem\z/ spec.summary = %q{Admin for Rails} spec.test_files = Dir['spec/**/*'] spec.version = RailsAdmin::Version From 04a534db153f14d3feda35386ce2c019fc3c3671 Mon Sep 17 00:00:00 2001 From: Erik Michaels-Ober Date: Sun, 3 Feb 2013 11:00:44 -0800 Subject: [PATCH 6/6] Don't hardcode my home directory --- rails_admin.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rails_admin.gemspec b/rails_admin.gemspec index a4b8bf67fa..568c614864 100644 --- a/rails_admin.gemspec +++ b/rails_admin.gemspec @@ -29,7 +29,7 @@ Gem::Specification.new do |spec| spec.name = 'rails_admin' spec.require_paths = ['lib'] spec.required_rubygems_version = '>= 1.3.6' - spec.signing_key = '/Users/sferik/.gem/private_key.pem' if $0 =~ /gem\z/ + spec.signing_key = File.expand_path("~/.gem/private_key.pem") if $0 =~ /gem\z/ spec.summary = %q{Admin for Rails} spec.test_files = Dir['spec/**/*'] spec.version = RailsAdmin::Version