enju_oai 0.1.0.pre16 → 0.1.0.pre17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (92) hide show
  1. checksums.yaml +4 -4
  2. data/README.rdoc +8 -1
  3. data/lib/enju_oai/version.rb +1 -1
  4. data/spec/dummy/bin/bundle +3 -0
  5. data/spec/dummy/bin/rails +4 -0
  6. data/spec/dummy/bin/rake +4 -0
  7. data/spec/dummy/bin/setup +29 -0
  8. data/spec/dummy/config/application.rb +1 -1
  9. data/spec/dummy/config/database.yml +23 -18
  10. data/spec/dummy/config/environments/test.rb +1 -1
  11. data/spec/dummy/db/migrate/005_create_manifestations.rb +0 -1
  12. data/spec/dummy/db/migrate/20100925074559_create_agent_import_results.rb +0 -1
  13. data/spec/dummy/db/migrate/20140518050147_create_reserve_transitions.rb +5 -1
  14. data/spec/dummy/db/migrate/20140519170214_create_resource_import_file_transitions.rb +5 -1
  15. data/spec/dummy/db/migrate/20140519171220_create_import_request_transitions.rb +5 -1
  16. data/spec/dummy/db/migrate/20140523171309_create_event_import_file_transitions.rb +5 -1
  17. data/spec/dummy/db/migrate/20140524020735_create_agent_import_file_transitions.rb +5 -1
  18. data/spec/dummy/db/migrate/20140524074813_create_user_import_file_transitions.rb +5 -1
  19. data/spec/dummy/db/migrate/20140528045518_create_user_checkout_stat_transitions.rb +5 -1
  20. data/spec/dummy/db/migrate/20140528045539_create_user_reserve_stat_transitions.rb +5 -1
  21. data/spec/dummy/db/migrate/20140528045600_create_manifestation_checkout_stat_transitions.rb +5 -1
  22. data/spec/dummy/db/migrate/20140528045617_create_manifestation_reserve_stat_transitions.rb +5 -1
  23. data/spec/dummy/db/migrate/20140614141500_create_resource_export_file_transitions.rb +5 -1
  24. data/spec/dummy/db/migrate/20140709113905_create_user_export_file_transitions.rb +5 -1
  25. data/spec/dummy/db/migrate/20140812153137_create_event_export_file_transitions.rb +5 -1
  26. data/spec/dummy/db/migrate/20140821151023_create_colors.rb +14 -0
  27. data/spec/dummy/db/migrate/20141003181336_add_full_name_transcription_to_profile.rb +5 -0
  28. data/spec/dummy/db/migrate/20141003182825_add_date_of_birth_to_profile.rb +5 -0
  29. data/spec/dummy/db/migrate/20141014065831_add_shelf_id_to_checkout.rb +6 -0
  30. data/spec/dummy/db/schema.rb +119 -108
  31. data/spec/fixtures/agent_import_results.yml +0 -3
  32. data/spec/fixtures/events.yml +13 -39
  33. data/spec/fixtures/manifestations.yml +114 -114
  34. data/spec/fixtures/users.yml +1 -1
  35. data/spec/spec_helper.rb +2 -0
  36. metadata +53 -121
  37. data/spec/dummy/db/development.sqlite3 +0 -0
  38. data/spec/dummy/db/migrate/20121116033446_add_doi_to_manifestation.rb +0 -6
  39. data/spec/dummy/db/test.sqlite3 +0 -0
  40. data/spec/dummy/script/rails +0 -6
  41. data/spec/dummy/solr/conf/admin-extra.html +0 -31
  42. data/spec/dummy/solr/conf/elevate.xml +0 -36
  43. data/spec/dummy/solr/conf/mapping-ISOLatin1Accent.txt +0 -246
  44. data/spec/dummy/solr/conf/protwords.txt +0 -21
  45. data/spec/dummy/solr/conf/schema.xml +0 -255
  46. data/spec/dummy/solr/conf/scripts.conf +0 -24
  47. data/spec/dummy/solr/conf/solrconfig.xml +0 -667
  48. data/spec/dummy/solr/conf/spellings.txt +0 -2
  49. data/spec/dummy/solr/conf/stopwords.txt +0 -58
  50. data/spec/dummy/solr/conf/synonyms.txt +0 -31
  51. data/spec/dummy/solr/default/data/index/_cs.fdt +0 -0
  52. data/spec/dummy/solr/default/data/index/_cs.fdx +0 -0
  53. data/spec/dummy/solr/default/data/index/_cs.fnm +0 -0
  54. data/spec/dummy/solr/default/data/index/_cs.nvd +0 -0
  55. data/spec/dummy/solr/default/data/index/_cs.nvm +0 -0
  56. data/spec/dummy/solr/default/data/index/_cs.si +0 -0
  57. data/spec/dummy/solr/default/data/index/_cs_Lucene41_0.doc +0 -0
  58. data/spec/dummy/solr/default/data/index/_cs_Lucene41_0.pos +0 -0
  59. data/spec/dummy/solr/default/data/index/_cs_Lucene41_0.tim +0 -0
  60. data/spec/dummy/solr/default/data/index/_cs_Lucene41_0.tip +0 -0
  61. data/spec/dummy/solr/default/data/index/_ct.fdt +0 -0
  62. data/spec/dummy/solr/default/data/index/_ct.fdx +0 -0
  63. data/spec/dummy/solr/default/data/index/_ct.fnm +0 -0
  64. data/spec/dummy/solr/default/data/index/_ct.nvd +0 -0
  65. data/spec/dummy/solr/default/data/index/_ct.nvm +0 -0
  66. data/spec/dummy/solr/default/data/index/_ct.si +0 -0
  67. data/spec/dummy/solr/default/data/index/_ct_Lucene41_0.doc +0 -0
  68. data/spec/dummy/solr/default/data/index/_ct_Lucene41_0.pos +0 -0
  69. data/spec/dummy/solr/default/data/index/_ct_Lucene41_0.tim +0 -0
  70. data/spec/dummy/solr/default/data/index/_ct_Lucene41_0.tip +0 -0
  71. data/spec/dummy/solr/default/data/index/_cu.fdt +0 -0
  72. data/spec/dummy/solr/default/data/index/_cu.fdx +0 -0
  73. data/spec/dummy/solr/default/data/index/_cu.fnm +0 -0
  74. data/spec/dummy/solr/default/data/index/_cu.nvd +0 -0
  75. data/spec/dummy/solr/default/data/index/_cu.nvm +0 -0
  76. data/spec/dummy/solr/default/data/index/_cu.si +0 -0
  77. data/spec/dummy/solr/default/data/index/_cu_Lucene41_0.doc +0 -0
  78. data/spec/dummy/solr/default/data/index/_cu_Lucene41_0.pos +0 -0
  79. data/spec/dummy/solr/default/data/index/_cu_Lucene41_0.tim +0 -0
  80. data/spec/dummy/solr/default/data/index/_cu_Lucene41_0.tip +0 -0
  81. data/spec/dummy/solr/default/data/index/segments.gen +0 -0
  82. data/spec/dummy/solr/default/data/index/segments_hj +0 -0
  83. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000627 +0 -0
  84. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000628 +0 -0
  85. data/spec/dummy/solr/default/data/tlog/tlog.0000000000000000629 +0 -0
  86. data/spec/dummy/solr/development/data/index/segments.gen +0 -0
  87. data/spec/dummy/solr/development/data/index/segments_1 +0 -0
  88. data/spec/dummy/solr/solr.xml +0 -8
  89. data/spec/dummy/solr/test/data/index/segments.gen +0 -0
  90. data/spec/dummy/solr/test/data/index/segments_1 +0 -0
  91. data/spec/dummy/tmp/cache/4F7/F90/default_role +0 -0
  92. data/spec/dummy/tmp/cache/6E4/420/search_engine_all +0 -0
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9d1659b6846f990190723b59b99e6c3ee6f74af6
4
- data.tar.gz: ddb71b1da9fafce72e106776b89dfe4e2158433b
3
+ metadata.gz: c1ed8452c675b787d03487c124014cc8743bb77e
4
+ data.tar.gz: 89472c34c9f5dcc8d0e3dbf653d8dfc9283c88b0
5
5
  SHA512:
6
- metadata.gz: 39150061ccb11b19000acc7d8bc6ca8059c1438bb4498dfa5cb477d8b92159c8e4cdeff6a42b87e619c1d51dc3dca1eac1b7d2a469fb43a3af03cf56525debd2
7
- data.tar.gz: a3a152cd898ccb454cdb1427f7822914db32fc72fbad9a3f5d6446fbc80d7ead063ee625fecc943772a1c68b20092cb8b1f3fad64825ac7035a4f9cbce6bf190
6
+ metadata.gz: 75a5577aa209863b0ad304839026fce4426bfaba08b93fdaa550dea7a0b941475b3efdc6e585c04d837f77faaf189f026eab656186d6885fcce8b3e499374ab1
7
+ data.tar.gz: 7e26b926ee5c8759f6aaa159cda3c0e0a53a2ac69f53ece3077aeb989f51644e7acbccde05ef4a30d07a86135ca9ebb47fde12e1b805e08f64a2342cbb76ffdd
data/README.rdoc CHANGED
@@ -1,3 +1,10 @@
1
1
  = EnjuOai
2
+ {<img src="https://secure.travis-ci.org/next-l/enju_oai.png?branch=1.1" alt="Build Status" />}[http://travis-ci.org/next-l/enju_oai]
3
+ {<img src="https://coveralls.io/repos/next-l/enju_oai/badge.png?branch=1.1" alt="Coverage Status" />}[https://coveralls.io/r/next-l/enju_oai?branch=1.1]
4
+ {<img src="https://hakiri.io/github/next-l/enju_oai/1.1.svg" alt="security" />}[https://hakiri.io/github/next-l/enju_oai/1.1]
2
5
 
3
- This project rocks and uses MIT-LICENSE.
6
+ This project rocks and uses MIT-LICENSE.
7
+
8
+ == 製作者・貢献者 (Authors and contributors)
9
+ * {TANABE, Kosuke}[https://github.com/nabeta] ({@nabeta}[https://twitter.com/nabeta])
10
+ * {Project Next-L}[http://www.next-l.jp] ({@ProjectNextL}[https://twitter.com/ProjectNextL])
@@ -1,3 +1,3 @@
1
1
  module EnjuOai
2
- VERSION = "0.1.0.pre16"
2
+ VERSION = "0.1.0.pre17"
3
3
  end
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env ruby
2
+ ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
3
+ load Gem.bin_path('bundler', 'bundle')
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ APP_PATH = File.expand_path('../../config/application', __FILE__)
3
+ require_relative '../config/boot'
4
+ require 'rails/commands'
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env ruby
2
+ require_relative '../config/boot'
3
+ require 'rake'
4
+ Rake.application.run
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env ruby
2
+ require 'pathname'
3
+
4
+ # path to your application root.
5
+ APP_ROOT = Pathname.new File.expand_path('../../', __FILE__)
6
+
7
+ Dir.chdir APP_ROOT do
8
+ # This script is a starting point to setup your application.
9
+ # Add necessary setup steps to this file:
10
+
11
+ puts "== Installing dependencies =="
12
+ system "gem install bundler --conservative"
13
+ system "bundle check || bundle install"
14
+
15
+ # puts "\n== Copying sample files =="
16
+ # unless File.exist?("config/database.yml")
17
+ # system "cp config/database.yml.sample config/database.yml"
18
+ # end
19
+
20
+ puts "\n== Preparing database =="
21
+ system "bin/rake db:setup"
22
+
23
+ puts "\n== Removing old logs and tempfiles =="
24
+ system "rm -f log/*"
25
+ system "rm -rf tmp/cache"
26
+
27
+ puts "\n== Restarting application server =="
28
+ system "touch tmp/restart.txt"
29
+ end
@@ -44,7 +44,7 @@ module Dummy
44
44
  # This will create an empty whitelist of attributes available for mass-assignment for all models
45
45
  # in your app. As such, your models will need to explicitly whitelist or blacklist accessible
46
46
  # parameters by using an attr_accessible or attr_protected declaration.
47
- config.active_record.whitelist_attributes = true
47
+ #config.active_record.whitelist_attributes = true
48
48
 
49
49
  # Enable the asset pipeline
50
50
  config.assets.enabled = true
@@ -1,25 +1,30 @@
1
- # SQLite version 3.x
2
- # gem install sqlite3
3
- #
4
- # Ensure the SQLite 3 gem is defined in your Gemfile
5
- # gem 'sqlite3'
6
- development:
1
+ sqlite: &sqlite
7
2
  adapter: sqlite3
8
- database: db/development.sqlite3
3
+ database: db/<%= Rails.env %>.sqlite3
4
+
5
+ mysql: &mysql
6
+ adapter: mysql2
7
+ username: root
8
+ password:
9
+ database: enju_<%= Rails.env %>
10
+
11
+ postgresql: &postgresql
12
+ adapter: postgresql
13
+ username: postgres
14
+ password:
15
+ database: enju_<%= Rails.env %>
16
+
17
+ defaults: &defaults
9
18
  pool: 5
10
19
  timeout: 5000
20
+ host: localhost
21
+ <<: *<%= ENV['DB'] || "sqlite" %>
22
+
23
+ development:
24
+ <<: *defaults
11
25
 
12
- # Warning: The database defined as "test" will be erased and
13
- # re-generated from your development database when you run "rake".
14
- # Do not set this db to the same as development or production.
15
26
  test:
16
- adapter: sqlite3
17
- database: db/test.sqlite3
18
- pool: 5
19
- timeout: 5000
27
+ <<: *defaults
20
28
 
21
29
  production:
22
- adapter: sqlite3
23
- database: db/production.sqlite3
24
- pool: 5
25
- timeout: 5000
30
+ <<: *defaults
@@ -30,7 +30,7 @@ Dummy::Application.configure do
30
30
  config.action_mailer.delivery_method = :test
31
31
 
32
32
  # Raise exception on mass assignment protection for Active Record models
33
- config.active_record.mass_assignment_sanitizer = :strict
33
+ #config.active_record.mass_assignment_sanitizer = :strict
34
34
 
35
35
  # Print deprecation notices to the stderr
36
36
  config.active_support.deprecation = :stderr
@@ -13,7 +13,6 @@ class CreateManifestations < ActiveRecord::Migration
13
13
  t.string :access_address
14
14
  t.integer :language_id, :default => 1, :null => false
15
15
  t.integer :carrier_type_id, :default => 1, :null => false
16
- t.integer :extent_id, :default => 1, :null => false
17
16
  t.integer :start_page
18
17
  t.integer :end_page
19
18
  t.integer :height
@@ -3,7 +3,6 @@ class CreateAgentImportResults < ActiveRecord::Migration
3
3
  create_table :agent_import_results do |t|
4
4
  t.integer :agent_import_file_id
5
5
  t.integer :agent_id
6
- t.integer :user_id
7
6
  t.text :body
8
7
 
9
8
  t.timestamps
@@ -2,7 +2,11 @@ class CreateReserveTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :reserve_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :reserve_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateResourceImportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :resource_import_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :resource_import_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateImportRequestTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :import_request_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :import_request_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateEventImportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :event_import_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :event_import_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateAgentImportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :agent_import_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :agent_import_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateUserImportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :user_import_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :user_import_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateUserCheckoutStatTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :user_checkout_stat_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :user_checkout_stat_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateUserReserveStatTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :user_reserve_stat_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :user_reserve_stat_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateManifestationCheckoutStatTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :manifestation_checkout_stat_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :manifestation_checkout_stat_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateManifestationReserveStatTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :manifestation_reserve_stat_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :manifestation_reserve_stat_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateResourceExportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :resource_export_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :resource_export_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateUserExportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :user_export_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :user_export_file_id
8
12
  t.timestamps
@@ -2,7 +2,11 @@ class CreateEventExportFileTransitions < ActiveRecord::Migration
2
2
  def change
3
3
  create_table :event_export_file_transitions do |t|
4
4
  t.string :to_state
5
- t.text :metadata, default: "{}"
5
+ if ActiveRecord::Base.configurations[Rails.env]["adapter"].try(:match, /mysql/)
6
+ t.text :metadata
7
+ else
8
+ t.text :metadata, default: "{}"
9
+ end
6
10
  t.integer :sort_key
7
11
  t.integer :event_export_file_id
8
12
  t.timestamps
@@ -0,0 +1,14 @@
1
+ class CreateColors < ActiveRecord::Migration
2
+ def change
3
+ create_table :colors do |t|
4
+ t.integer :library_group_id
5
+ t.string :property
6
+ t.string :code
7
+ t.integer :position
8
+
9
+ t.timestamps
10
+ end
11
+
12
+ add_index :colors, :library_group_id
13
+ end
14
+ end
@@ -0,0 +1,5 @@
1
+ class AddFullNameTranscriptionToProfile < ActiveRecord::Migration
2
+ def change
3
+ add_column :profiles, :full_name_transcription, :text
4
+ end
5
+ end
@@ -0,0 +1,5 @@
1
+ class AddDateOfBirthToProfile < ActiveRecord::Migration
2
+ def change
3
+ add_column :profiles, :date_of_birth, :datetime
4
+ end
5
+ end
@@ -0,0 +1,6 @@
1
+ class AddShelfIdToCheckout < ActiveRecord::Migration
2
+ def change
3
+ add_column :checkouts, :shelf_id, :integer
4
+ add_index :checkouts, :shelf_id
5
+ end
6
+ end