jp_address 1.0.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +57 -0
  3. data/MIT-LICENSE +0 -0
  4. data/README.md +98 -97
  5. data/Rakefile +14 -15
  6. data/app/controllers/jp_address/application_controller.rb +1 -0
  7. data/app/controllers/jp_address/zipcodes_controller.rb +9 -4
  8. data/app/models/jp_address/application_record.rb +5 -0
  9. data/app/models/jp_address/zipcode.rb +166 -36
  10. data/config/routes.rb +0 -0
  11. data/db/migrate/20160312045953_create_jp_address_zipcodes.rb +1 -1
  12. data/lib/jp_address/engine.rb +0 -0
  13. data/lib/jp_address/version.rb +1 -1
  14. data/lib/jp_address.rb +3 -1
  15. data/lib/tasks/jp_address_tasks.rake +0 -0
  16. metadata +48 -157
  17. data/app/assets/javascripts/jp_address/application.js +0 -13
  18. data/app/assets/stylesheets/jp_address/application.css +0 -15
  19. data/app/helpers/jp_address/application_helper.rb +0 -4
  20. data/app/views/layouts/jp_address/application.html.erb +0 -14
  21. data/spec/controllers/jp_address/zipcodes_controller_spec.rb +0 -25
  22. data/spec/dummy/README.rdoc +0 -28
  23. data/spec/dummy/Rakefile +0 -6
  24. data/spec/dummy/app/assets/config/manifest.js +0 -2
  25. data/spec/dummy/app/assets/javascripts/application.js +0 -13
  26. data/spec/dummy/app/assets/stylesheets/application.css +0 -15
  27. data/spec/dummy/app/controllers/application_controller.rb +0 -5
  28. data/spec/dummy/app/helpers/application_helper.rb +0 -2
  29. data/spec/dummy/app/views/layouts/application.html.erb +0 -14
  30. data/spec/dummy/bin/bundle +0 -3
  31. data/spec/dummy/bin/rails +0 -4
  32. data/spec/dummy/bin/rake +0 -4
  33. data/spec/dummy/bin/setup +0 -29
  34. data/spec/dummy/config/application.rb +0 -31
  35. data/spec/dummy/config/boot.rb +0 -5
  36. data/spec/dummy/config/database.yml +0 -25
  37. data/spec/dummy/config/environment.rb +0 -5
  38. data/spec/dummy/config/environments/development.rb +0 -41
  39. data/spec/dummy/config/environments/production.rb +0 -79
  40. data/spec/dummy/config/environments/test.rb +0 -42
  41. data/spec/dummy/config/initializers/assets.rb +0 -11
  42. data/spec/dummy/config/initializers/backtrace_silencers.rb +0 -7
  43. data/spec/dummy/config/initializers/cookies_serializer.rb +0 -3
  44. data/spec/dummy/config/initializers/filter_parameter_logging.rb +0 -4
  45. data/spec/dummy/config/initializers/inflections.rb +0 -16
  46. data/spec/dummy/config/initializers/mime_types.rb +0 -4
  47. data/spec/dummy/config/initializers/session_store.rb +0 -3
  48. data/spec/dummy/config/initializers/wrap_parameters.rb +0 -14
  49. data/spec/dummy/config/locales/en.yml +0 -23
  50. data/spec/dummy/config/routes.rb +0 -3
  51. data/spec/dummy/config/secrets.yml +0 -22
  52. data/spec/dummy/config.ru +0 -4
  53. data/spec/dummy/db/schema.rb +0 -25
  54. data/spec/dummy/db/test.sqlite3 +0 -0
  55. data/spec/dummy/log/test.log +0 -6
  56. data/spec/dummy/public/404.html +0 -67
  57. data/spec/dummy/public/422.html +0 -67
  58. data/spec/dummy/public/500.html +0 -66
  59. data/spec/dummy/public/favicon.ico +0 -0
  60. data/spec/factories/jp_address_zipcodes.rb +0 -10
  61. data/spec/models/jp_address/zipcode_spec.rb +0 -29
  62. data/spec/rails_helper.rb +0 -15
  63. data/spec/spec_helper.rb +0 -92
  64. data/spec/support/files/sample_ken.csv +0 -5
  65. data/spec/vcr/download_master_file_from_japanpost.yml +0 -37476
File without changes
@@ -1,3 +1,3 @@
1
1
  module JpAddress
2
- VERSION = "1.0.1"
2
+ VERSION = "2.0.0"
3
3
  end
data/lib/jp_address.rb CHANGED
@@ -1,9 +1,11 @@
1
1
  require 'net/https'
2
2
  require 'uri'
3
3
  require 'tempfile'
4
+ require 'fileutils'
4
5
  require 'csv'
5
6
  require 'zip'
6
- require "jp_address/engine"
7
+ require 'jp_address/version'
8
+ require 'jp_address/engine'
7
9
 
8
10
  module JpAddress
9
11
  end
File without changes
metadata CHANGED
@@ -1,113 +1,94 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jp_address
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tad Kam
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2021-06-10 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
- name: rubyzip
13
+ name: railties
15
14
  requirement: !ruby/object:Gem::Requirement
16
15
  requirements:
17
16
  - - ">="
18
17
  - !ruby/object:Gem::Version
19
- version: '0'
18
+ version: '7.1'
19
+ - - "<"
20
+ - !ruby/object:Gem::Version
21
+ version: '9.0'
20
22
  type: :runtime
21
23
  prerelease: false
22
24
  version_requirements: !ruby/object:Gem::Requirement
23
25
  requirements:
24
26
  - - ">="
25
27
  - !ruby/object:Gem::Version
26
- version: '0'
27
- - !ruby/object:Gem::Dependency
28
- name: rails
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
28
+ version: '7.1'
29
+ - - "<"
32
30
  - !ruby/object:Gem::Version
33
- version: '0'
34
- type: :development
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - ">="
39
- - !ruby/object:Gem::Version
40
- version: '0'
31
+ version: '9.0'
41
32
  - !ruby/object:Gem::Dependency
42
- name: sqlite3
33
+ name: activerecord
43
34
  requirement: !ruby/object:Gem::Requirement
44
35
  requirements:
45
36
  - - ">="
46
37
  - !ruby/object:Gem::Version
47
- version: '0'
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - ">="
53
- - !ruby/object:Gem::Version
54
- version: '0'
55
- - !ruby/object:Gem::Dependency
56
- name: rspec-rails
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - ">="
38
+ version: '7.1'
39
+ - - "<"
60
40
  - !ruby/object:Gem::Version
61
- version: '0'
62
- type: :development
41
+ version: '9.0'
42
+ type: :runtime
63
43
  prerelease: false
64
44
  version_requirements: !ruby/object:Gem::Requirement
65
45
  requirements:
66
46
  - - ">="
67
47
  - !ruby/object:Gem::Version
68
- version: '0'
69
- - !ruby/object:Gem::Dependency
70
- name: factory_bot_rails
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - ">="
48
+ version: '7.1'
49
+ - - "<"
74
50
  - !ruby/object:Gem::Version
75
- version: '0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: '0'
51
+ version: '9.0'
83
52
  - !ruby/object:Gem::Dependency
84
- name: webmock
53
+ name: rubyzip
85
54
  requirement: !ruby/object:Gem::Requirement
86
55
  requirements:
87
56
  - - ">="
88
57
  - !ruby/object:Gem::Version
89
- version: '0'
90
- type: :development
58
+ version: '2.3'
59
+ - - "<"
60
+ - !ruby/object:Gem::Version
61
+ version: '4.0'
62
+ type: :runtime
91
63
  prerelease: false
92
64
  version_requirements: !ruby/object:Gem::Requirement
93
65
  requirements:
94
66
  - - ">="
95
67
  - !ruby/object:Gem::Version
96
- version: '0'
68
+ version: '2.3'
69
+ - - "<"
70
+ - !ruby/object:Gem::Version
71
+ version: '4.0'
97
72
  - !ruby/object:Gem::Dependency
98
- name: vcr
73
+ name: csv
99
74
  requirement: !ruby/object:Gem::Requirement
100
75
  requirements:
101
76
  - - ">="
102
77
  - !ruby/object:Gem::Version
103
- version: '0'
104
- type: :development
78
+ version: '3.0'
79
+ - - "<"
80
+ - !ruby/object:Gem::Version
81
+ version: '4.0'
82
+ type: :runtime
105
83
  prerelease: false
106
84
  version_requirements: !ruby/object:Gem::Requirement
107
85
  requirements:
108
86
  - - ">="
109
87
  - !ruby/object:Gem::Version
110
- version: '0'
88
+ version: '3.0'
89
+ - - "<"
90
+ - !ruby/object:Gem::Version
91
+ version: '4.0'
111
92
  description: JpAddress is simple japan-zipcode-address-search API. You can load master-data
112
93
  from JapanPost and mount address-search-api to your rails application.
113
94
  email:
@@ -116,72 +97,28 @@ executables: []
116
97
  extensions: []
117
98
  extra_rdoc_files: []
118
99
  files:
100
+ - CHANGELOG.md
119
101
  - MIT-LICENSE
120
102
  - README.md
121
103
  - Rakefile
122
- - app/assets/javascripts/jp_address/application.js
123
- - app/assets/stylesheets/jp_address/application.css
124
104
  - app/controllers/jp_address/application_controller.rb
125
105
  - app/controllers/jp_address/zipcodes_controller.rb
126
- - app/helpers/jp_address/application_helper.rb
106
+ - app/models/jp_address/application_record.rb
127
107
  - app/models/jp_address/zipcode.rb
128
- - app/views/layouts/jp_address/application.html.erb
129
108
  - config/routes.rb
130
109
  - db/migrate/20160312045953_create_jp_address_zipcodes.rb
131
110
  - lib/jp_address.rb
132
111
  - lib/jp_address/engine.rb
133
112
  - lib/jp_address/version.rb
134
113
  - lib/tasks/jp_address_tasks.rake
135
- - spec/controllers/jp_address/zipcodes_controller_spec.rb
136
- - spec/dummy/README.rdoc
137
- - spec/dummy/Rakefile
138
- - spec/dummy/app/assets/config/manifest.js
139
- - spec/dummy/app/assets/javascripts/application.js
140
- - spec/dummy/app/assets/stylesheets/application.css
141
- - spec/dummy/app/controllers/application_controller.rb
142
- - spec/dummy/app/helpers/application_helper.rb
143
- - spec/dummy/app/views/layouts/application.html.erb
144
- - spec/dummy/bin/bundle
145
- - spec/dummy/bin/rails
146
- - spec/dummy/bin/rake
147
- - spec/dummy/bin/setup
148
- - spec/dummy/config.ru
149
- - spec/dummy/config/application.rb
150
- - spec/dummy/config/boot.rb
151
- - spec/dummy/config/database.yml
152
- - spec/dummy/config/environment.rb
153
- - spec/dummy/config/environments/development.rb
154
- - spec/dummy/config/environments/production.rb
155
- - spec/dummy/config/environments/test.rb
156
- - spec/dummy/config/initializers/assets.rb
157
- - spec/dummy/config/initializers/backtrace_silencers.rb
158
- - spec/dummy/config/initializers/cookies_serializer.rb
159
- - spec/dummy/config/initializers/filter_parameter_logging.rb
160
- - spec/dummy/config/initializers/inflections.rb
161
- - spec/dummy/config/initializers/mime_types.rb
162
- - spec/dummy/config/initializers/session_store.rb
163
- - spec/dummy/config/initializers/wrap_parameters.rb
164
- - spec/dummy/config/locales/en.yml
165
- - spec/dummy/config/routes.rb
166
- - spec/dummy/config/secrets.yml
167
- - spec/dummy/db/schema.rb
168
- - spec/dummy/db/test.sqlite3
169
- - spec/dummy/log/test.log
170
- - spec/dummy/public/404.html
171
- - spec/dummy/public/422.html
172
- - spec/dummy/public/500.html
173
- - spec/dummy/public/favicon.ico
174
- - spec/factories/jp_address_zipcodes.rb
175
- - spec/models/jp_address/zipcode_spec.rb
176
- - spec/rails_helper.rb
177
- - spec/spec_helper.rb
178
- - spec/support/files/sample_ken.csv
179
- - spec/vcr/download_master_file_from_japanpost.yml
180
114
  homepage: https://github.com/densya203/jp_address
181
115
  licenses:
182
116
  - MIT
183
- metadata: {}
184
- post_install_message:
117
+ metadata:
118
+ homepage_uri: https://github.com/densya203/jp_address
119
+ source_code_uri: https://github.com/densya203/jp_address/tree/v2.0.0
120
+ bug_tracker_uri: https://github.com/densya203/jp_address/issues
121
+ changelog_uri: https://github.com/densya203/jp_address/blob/master/CHANGELOG.md
185
122
  rdoc_options: []
186
123
  require_paths:
187
124
  - lib
@@ -189,60 +126,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
189
126
  requirements:
190
127
  - - ">="
191
128
  - !ruby/object:Gem::Version
192
- version: '0'
129
+ version: 3.1.0
193
130
  required_rubygems_version: !ruby/object:Gem::Requirement
194
131
  requirements:
195
132
  - - ">="
196
133
  - !ruby/object:Gem::Version
197
134
  version: '0'
198
135
  requirements: []
199
- rubygems_version: 3.1.4
200
- signing_key:
136
+ rubygems_version: 3.6.9
201
137
  specification_version: 4
202
138
  summary: Simple japan-zipcode-addresses API
203
- test_files:
204
- - spec/controllers/jp_address/zipcodes_controller_spec.rb
205
- - spec/dummy/README.rdoc
206
- - spec/dummy/Rakefile
207
- - spec/dummy/app/assets/config/manifest.js
208
- - spec/dummy/app/assets/javascripts/application.js
209
- - spec/dummy/app/assets/stylesheets/application.css
210
- - spec/dummy/app/controllers/application_controller.rb
211
- - spec/dummy/app/helpers/application_helper.rb
212
- - spec/dummy/app/views/layouts/application.html.erb
213
- - spec/dummy/bin/bundle
214
- - spec/dummy/bin/rails
215
- - spec/dummy/bin/rake
216
- - spec/dummy/bin/setup
217
- - spec/dummy/config/application.rb
218
- - spec/dummy/config/boot.rb
219
- - spec/dummy/config/database.yml
220
- - spec/dummy/config/environment.rb
221
- - spec/dummy/config/environments/development.rb
222
- - spec/dummy/config/environments/production.rb
223
- - spec/dummy/config/environments/test.rb
224
- - spec/dummy/config/initializers/assets.rb
225
- - spec/dummy/config/initializers/backtrace_silencers.rb
226
- - spec/dummy/config/initializers/cookies_serializer.rb
227
- - spec/dummy/config/initializers/filter_parameter_logging.rb
228
- - spec/dummy/config/initializers/inflections.rb
229
- - spec/dummy/config/initializers/mime_types.rb
230
- - spec/dummy/config/initializers/session_store.rb
231
- - spec/dummy/config/initializers/wrap_parameters.rb
232
- - spec/dummy/config/locales/en.yml
233
- - spec/dummy/config/routes.rb
234
- - spec/dummy/config/secrets.yml
235
- - spec/dummy/config.ru
236
- - spec/dummy/db/schema.rb
237
- - spec/dummy/db/test.sqlite3
238
- - spec/dummy/log/test.log
239
- - spec/dummy/public/404.html
240
- - spec/dummy/public/422.html
241
- - spec/dummy/public/500.html
242
- - spec/dummy/public/favicon.ico
243
- - spec/factories/jp_address_zipcodes.rb
244
- - spec/models/jp_address/zipcode_spec.rb
245
- - spec/rails_helper.rb
246
- - spec/spec_helper.rb
247
- - spec/support/files/sample_ken.csv
248
- - spec/vcr/download_master_file_from_japanpost.yml
139
+ test_files: []
@@ -1,13 +0,0 @@
1
- // This is a manifest file that'll be compiled into application.js, which will include all the files
2
- // listed below.
3
- //
4
- // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
- //
7
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
9
- //
10
- // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
- // about supported directives.
12
- //
13
- //= require_tree .
@@ -1,15 +0,0 @@
1
- /*
2
- * This is a manifest file that'll be compiled into application.css, which will include all the files
3
- * listed below.
4
- *
5
- * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
- * or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
7
- *
8
- * You're free to add application-wide styles to this file and they'll appear at the bottom of the
9
- * compiled file so the styles you add here take precedence over styles defined in any styles
10
- * defined in the other CSS/SCSS files in this directory. It is generally better to create a new
11
- * file per style scope.
12
- *
13
- *= require_tree .
14
- *= require_self
15
- */
@@ -1,4 +0,0 @@
1
- module JpAddress
2
- module ApplicationHelper
3
- end
4
- end
@@ -1,14 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>JpAddress</title>
5
- <%= stylesheet_link_tag "jp_address/application", media: "all" %>
6
- <%= javascript_include_tag "jp_address/application" %>
7
- <%= csrf_meta_tags %>
8
- </head>
9
- <body>
10
-
11
- <%= yield %>
12
-
13
- </body>
14
- </html>
@@ -1,25 +0,0 @@
1
- require 'rails_helper'
2
-
3
- module JpAddress
4
- RSpec.describe ZipcodesController, type: :controller do
5
- routes { JpAddress::Engine.routes }
6
-
7
- describe "GET #search" do
8
- it "returns http success" do
9
- get :search
10
- expect(response).to have_http_status(:success)
11
- end
12
- it "returns valid data when a vaild zip is passed" do
13
- FactoryBot.create(:jp_address_zipcode)
14
- get :search, params: {zip: '5330033'}
15
- expect(response.body).to match '"zip":"5330033","prefecture":"大阪府","city":"大阪市東淀川区","town":"東中島"'
16
- end
17
- it "returns empty data when a invaild zip is passed" do
18
- FactoryBot.create(:jp_address_zipcode)
19
- get :search, params: {zip: '9999999'}
20
- expect(response.body).to match '"id":null,"zip":null,"prefecture":null,"city":null,"town":null'
21
- end
22
- end
23
-
24
- end
25
- end
@@ -1,28 +0,0 @@
1
- == README
2
-
3
- This README would normally document whatever steps are necessary to get the
4
- application up and running.
5
-
6
- Things you may want to cover:
7
-
8
- * Ruby version
9
-
10
- * System dependencies
11
-
12
- * Configuration
13
-
14
- * Database creation
15
-
16
- * Database initialization
17
-
18
- * How to run the test suite
19
-
20
- * Services (job queues, cache servers, search engines, etc.)
21
-
22
- * Deployment instructions
23
-
24
- * ...
25
-
26
-
27
- Please feel free to use a different markup language if you do not plan to run
28
- <tt>rake doc:app</tt>.
data/spec/dummy/Rakefile DELETED
@@ -1,6 +0,0 @@
1
- # Add your own tasks in files placed in lib/tasks ending in .rake,
2
- # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
3
-
4
- require File.expand_path('../config/application', __FILE__)
5
-
6
- Rails.application.load_tasks
@@ -1,2 +0,0 @@
1
- //= link_tree ../images
2
- //= link_directory ../stylesheets .css
@@ -1,13 +0,0 @@
1
- // This is a manifest file that'll be compiled into application.js, which will include all the files
2
- // listed below.
3
- //
4
- // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
- //
7
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
9
- //
10
- // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
- // about supported directives.
12
- //
13
- //= require_tree .
@@ -1,15 +0,0 @@
1
- /*
2
- * This is a manifest file that'll be compiled into application.css, which will include all the files
3
- * listed below.
4
- *
5
- * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
- * or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
7
- *
8
- * You're free to add application-wide styles to this file and they'll appear at the bottom of the
9
- * compiled file so the styles you add here take precedence over styles defined in any styles
10
- * defined in the other CSS/SCSS files in this directory. It is generally better to create a new
11
- * file per style scope.
12
- *
13
- *= require_tree .
14
- *= require_self
15
- */
@@ -1,5 +0,0 @@
1
- class ApplicationController < ActionController::Base
2
- # Prevent CSRF attacks by raising an exception.
3
- # For APIs, you may want to use :null_session instead.
4
- protect_from_forgery with: :exception
5
- end
@@ -1,2 +0,0 @@
1
- module ApplicationHelper
2
- end
@@ -1,14 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>Dummy</title>
5
- <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true %>
6
- <%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
7
- <%= csrf_meta_tags %>
8
- </head>
9
- <body>
10
-
11
- <%= yield %>
12
-
13
- </body>
14
- </html>
@@ -1,3 +0,0 @@
1
- #!/usr/bin/env ruby
2
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
3
- load Gem.bin_path('bundler', 'bundle')
data/spec/dummy/bin/rails DELETED
@@ -1,4 +0,0 @@
1
- #!/usr/bin/env ruby
2
- APP_PATH = File.expand_path('../../config/application', __FILE__)
3
- require_relative '../config/boot'
4
- require 'rails/commands'
data/spec/dummy/bin/rake DELETED
@@ -1,4 +0,0 @@
1
- #!/usr/bin/env ruby
2
- require_relative '../config/boot'
3
- require 'rake'
4
- Rake.application.run
data/spec/dummy/bin/setup DELETED
@@ -1,29 +0,0 @@
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
@@ -1,31 +0,0 @@
1
- require File.expand_path('../boot', __FILE__)
2
-
3
- # Pick the frameworks you want:
4
- require "active_record/railtie"
5
- require "action_controller/railtie"
6
- require "action_mailer/railtie"
7
- require "action_view/railtie"
8
- require "sprockets/railtie"
9
- # require "rails/test_unit/railtie"
10
-
11
- Bundler.require(*Rails.groups)
12
- require "jp_address"
13
-
14
- module Dummy
15
- class Application < Rails::Application
16
- # Settings in config/environments/* take precedence over those specified here.
17
- # Application configuration should go into files in config/initializers
18
- # -- all .rb files in that directory are automatically loaded.
19
-
20
- # Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
21
- # Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
22
- # config.time_zone = 'Central Time (US & Canada)'
23
-
24
- # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
25
- # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
26
- # config.i18n.default_locale = :de
27
-
28
- # config.active_record.sqlite3.represent_boolean_as_integer = true
29
- end
30
- end
31
-
@@ -1,5 +0,0 @@
1
- # Set up gems listed in the Gemfile.
2
- ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../../Gemfile', __FILE__)
3
-
4
- require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE'])
5
- $LOAD_PATH.unshift File.expand_path('../../../../lib', __FILE__)
@@ -1,25 +0,0 @@
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
- #
7
- default: &default
8
- adapter: sqlite3
9
- pool: 5
10
- timeout: 5000
11
-
12
- development:
13
- <<: *default
14
- database: db/development.sqlite3
15
-
16
- # Warning: The database defined as "test" will be erased and
17
- # re-generated from your development database when you run "rake".
18
- # Do not set this db to the same as development or production.
19
- test:
20
- <<: *default
21
- database: db/test.sqlite3
22
-
23
- production:
24
- <<: *default
25
- database: db/production.sqlite3
@@ -1,5 +0,0 @@
1
- # Load the Rails application.
2
- require File.expand_path('../application', __FILE__)
3
-
4
- # Initialize the Rails application.
5
- Rails.application.initialize!
@@ -1,41 +0,0 @@
1
- Rails.application.configure do
2
- # Settings specified here will take precedence over those in config/application.rb.
3
-
4
- # In the development environment your application's code is reloaded on
5
- # every request. This slows down response time but is perfect for development
6
- # since you don't have to restart the web server when you make code changes.
7
- config.cache_classes = false
8
-
9
- # Do not eager load code on boot.
10
- config.eager_load = false
11
-
12
- # Show full error reports and disable caching.
13
- config.consider_all_requests_local = true
14
- config.action_controller.perform_caching = false
15
-
16
- # Don't care if the mailer can't send.
17
- config.action_mailer.raise_delivery_errors = false
18
-
19
- # Print deprecation notices to the Rails logger.
20
- config.active_support.deprecation = :log
21
-
22
- # Raise an error on page load if there are pending migrations.
23
- config.active_record.migration_error = :page_load
24
-
25
- # Debug mode disables concatenation and preprocessing of assets.
26
- # This option may cause significant delays in view rendering with a large
27
- # number of complex assets.
28
- config.assets.debug = true
29
-
30
- # Asset digests allow you to set far-future HTTP expiration dates on all assets,
31
- # yet still be able to expire them through the digest params.
32
- config.assets.digest = true
33
-
34
- # Adds additional error checking when serving assets at runtime.
35
- # Checks for improperly declared sprockets dependencies.
36
- # Raises helpful error messages.
37
- config.assets.raise_runtime_errors = true
38
-
39
- # Raises error for missing translations
40
- # config.action_view.raise_on_missing_translations = true
41
- end