iqvoc_inflectionals 2.9.0 → 2.11.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.github/workflows/ci.yml +56 -0
- data/.gitignore +8 -0
- data/Gemfile +11 -7
- data/Gemfile.lock +482 -305
- data/README.md +1 -1
- data/app/assets/javascripts/manifest.js +3 -0
- data/app/assets/stylesheets/manifest.scss +3 -0
- data/app/models/concerns/inflectionable.rb +14 -4
- data/app/models/inflectional/base.rb +4 -19
- data/app/views/partials/inflectional/_base.html.erb +2 -12
- data/app/views/partials/inflectional/_edit_base.html.erb +2 -0
- data/bin/bundle +1 -1
- data/bin/rails +3 -3
- data/bin/rake +2 -2
- data/bin/setup +16 -12
- data/bin/update +31 -0
- data/bin/yarn +17 -0
- data/config/application.rb +30 -48
- data/config/boot.rb +3 -12
- data/config/cable.yml +10 -0
- data/config/database.yml.postgresql +26 -0
- data/config/environment.rb +4 -4
- data/config/initializers/content_security_policy.rb +25 -0
- data/config/initializers/filter_parameter_logging.rb +8 -0
- data/config/initializers/inflections.rb +16 -0
- data/config/initializers/permissions_policy.rb +11 -0
- data/config/storage.yml +34 -0
- data/config.ru +4 -2
- data/db/migrate/20120109143704_create_inflectionals.rb +1 -1
- data/db/migrate/20150108155020_add_fk_constraints_iqvoc_inflectionals.rb +1 -1
- data/db/migrate/20160127131143_add_inflectional_attributes_to_label.rb +1 -1
- data/db/migrate/20160331092532_change_inflectional_value_collation.rb +1 -1
- data/db/migrate/20200901140019_add_inflectionals_index.rb +5 -0
- data/faucet.config.js +46 -0
- data/iqvoc_inflectionals.gemspec +2 -2
- data/lib/iqvoc/inflectionals/version.rb +1 -1
- data/package-lock.json +1495 -0
- data/package.json +32 -0
- metadata +26 -20
- data/.travis.yml +0 -37
- data/app/assets/stylesheets/manifest.css.scss +0 -3
- data/bin/spring +0 -18
data/README.md
CHANGED
@@ -8,9 +8,19 @@ module Inflectionable
|
|
8
8
|
after_save :create_default_inflectional
|
9
9
|
|
10
10
|
has_many :inflectionals,
|
11
|
-
:
|
12
|
-
:
|
13
|
-
:
|
11
|
+
class_name: "Inflectional::Base",
|
12
|
+
foreign_key: "label_id",
|
13
|
+
dependent: :destroy,
|
14
|
+
inverse_of: :label
|
15
|
+
|
16
|
+
# overwrite class method to query labels by all existing inflectionals
|
17
|
+
# instead of basic xl-label value attribute
|
18
|
+
def self.by_query_value(query)
|
19
|
+
Iqvoc::XLLabel.base_class
|
20
|
+
.references(:inflectionals)
|
21
|
+
.joins(:inflectionals)
|
22
|
+
.where('inflectionals.value ILIKE ?', query.mb_chars.downcase.to_s)
|
23
|
+
end
|
14
24
|
end
|
15
25
|
|
16
26
|
def endings
|
@@ -52,7 +62,7 @@ module Inflectionable
|
|
52
62
|
|
53
63
|
def create_default_inflectional
|
54
64
|
# ensure a matching inflectional exists
|
55
|
-
if value && inflectionals.
|
65
|
+
if value && inflectionals.empty?
|
56
66
|
inflectionals.create(:value => value)
|
57
67
|
end
|
58
68
|
end
|
@@ -38,7 +38,7 @@ class Inflectional::Base < ActiveRecord::Base
|
|
38
38
|
end
|
39
39
|
|
40
40
|
def self.by_query_value(query)
|
41
|
-
where(["
|
41
|
+
where(["#{table_name}.value ILIKE ?", query.to_s.downcase])
|
42
42
|
end
|
43
43
|
|
44
44
|
MAPPINGS = {
|
@@ -286,29 +286,14 @@ class Inflectional::Base < ActiveRecord::Base
|
|
286
286
|
end
|
287
287
|
end
|
288
288
|
|
289
|
-
def self.forces_multi_query?
|
290
|
-
true
|
291
|
-
end
|
292
|
-
|
293
289
|
def self.single_query(params = {})
|
294
290
|
query_str = build_query_string(params)
|
295
291
|
|
296
292
|
scope = by_query_value(query_str).includes(:label)
|
297
|
-
scope = scope.references(:labels).merge(Iqvoc::XLLabel.base_class.by_language(params[:languages].to_a).published.order("
|
293
|
+
scope = scope.references(:labels).merge(Iqvoc::XLLabel.base_class.by_language(params[:languages].to_a).published.order("LENGTH(#{Label::Base.table_name}.value)"))
|
298
294
|
scope.map { |result| SearchResult.new(result) }
|
299
295
|
end
|
300
296
|
|
301
|
-
# def self.single_query(params = {})
|
302
|
-
# query_str = build_query_string(params)
|
303
|
-
#
|
304
|
-
# Label::UMT::Base.select("DISTINCT #{Label::UMT::Base.table_name}.*").
|
305
|
-
# joins(:inflectionals).
|
306
|
-
# where(Inflectional::Base.by_query_value(query_str)).
|
307
|
-
# by_language(params[:languages].to_a).
|
308
|
-
# published.
|
309
|
-
# order("LOWER(#{Inflectional::Base.table_name}.value)")
|
310
|
-
# end
|
311
|
-
|
312
297
|
def self.search_result_partial_name
|
313
298
|
'partials/inflectional/search_result'
|
314
299
|
end
|
@@ -323,11 +308,11 @@ class Inflectional::Base < ActiveRecord::Base
|
|
323
308
|
end
|
324
309
|
|
325
310
|
def self.view_section(obj)
|
326
|
-
"
|
311
|
+
"main"
|
327
312
|
end
|
328
313
|
|
329
314
|
def self.view_section_sort_key(obj)
|
330
|
-
|
315
|
+
300
|
331
316
|
end
|
332
317
|
|
333
318
|
def self.partial_name(obj)
|
@@ -2,13 +2,7 @@
|
|
2
2
|
<h2><%= t("txt.views.labels.inflectionals") %></h2>
|
3
3
|
<% labels_inflectionals_values = label.send(klass.name.to_relation_name).map(&:value) %>
|
4
4
|
|
5
|
-
|
6
|
-
<ul>
|
7
|
-
<% labels_inflectionals_values.each do |inf| %>
|
8
|
-
<li><%= inf %></li>
|
9
|
-
<% end %>
|
10
|
-
</ul>
|
11
|
-
<% end %>
|
5
|
+
<%= labels_inflectionals_values.join(', ') %>
|
12
6
|
|
13
7
|
<%
|
14
8
|
all_inflectionals = Inflectional::Base.where(:value => labels_inflectionals_values).all
|
@@ -18,10 +12,6 @@
|
|
18
12
|
|
19
13
|
<% if inflectionals_labels.present? %>
|
20
14
|
<p><%= t("txt.views.labels.inflectionals_used_in") %></p>
|
21
|
-
|
22
|
-
<% inflectionals_labels.each do |inf| %>
|
23
|
-
<li><%= link_to inf.value, label_path(:published => inf.published? ? nil : 0, :id => inf) %></li>
|
24
|
-
<% end %>
|
25
|
-
</ul>
|
15
|
+
<%= inflectionals_labels.map { |inf| link_to inf.value, label_path(:published => inf.published? ? nil : 0, :id => inf) }.join(', ').html_safe %>
|
26
16
|
<% end %>
|
27
17
|
</div>
|
data/bin/bundle
CHANGED
data/bin/rails
CHANGED
@@ -1,4 +1,4 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
APP_PATH = File.expand_path(
|
3
|
-
require_relative
|
4
|
-
require
|
2
|
+
APP_PATH = File.expand_path("../config/application", __dir__)
|
3
|
+
require_relative "../config/boot"
|
4
|
+
require "rails/commands"
|
data/bin/rake
CHANGED
data/bin/setup
CHANGED
@@ -1,29 +1,33 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
require
|
2
|
+
require "fileutils"
|
3
3
|
|
4
4
|
# path to your application root.
|
5
|
-
APP_ROOT =
|
5
|
+
APP_ROOT = File.expand_path("..", __dir__)
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
7
|
+
def system!(*args)
|
8
|
+
system(*args) || abort("\n== Command #{args} failed ==")
|
9
|
+
end
|
10
|
+
|
11
|
+
FileUtils.chdir APP_ROOT do
|
12
|
+
# This script is a way to set up or update your development environment automatically.
|
13
|
+
# This script is idempotent, so that you can run it at any time and get an expectable outcome.
|
14
|
+
# Add necessary setup steps to this file.
|
10
15
|
|
11
16
|
puts "== Installing dependencies =="
|
12
|
-
system "gem install bundler --conservative"
|
13
|
-
system
|
17
|
+
system! "gem install bundler --conservative"
|
18
|
+
system("bundle check") || system!("bundle install")
|
14
19
|
|
15
20
|
# puts "\n== Copying sample files =="
|
16
21
|
# unless File.exist?("config/database.yml")
|
17
|
-
#
|
22
|
+
# FileUtils.cp "config/database.yml.sample", "config/database.yml"
|
18
23
|
# end
|
19
24
|
|
20
25
|
puts "\n== Preparing database =="
|
21
|
-
system "bin/
|
26
|
+
system! "bin/rails db:prepare"
|
22
27
|
|
23
28
|
puts "\n== Removing old logs and tempfiles =="
|
24
|
-
system "
|
25
|
-
system "rm -rf tmp/cache"
|
29
|
+
system! "bin/rails log:clear tmp:clear"
|
26
30
|
|
27
31
|
puts "\n== Restarting application server =="
|
28
|
-
system "
|
32
|
+
system! "bin/rails restart"
|
29
33
|
end
|
data/bin/update
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require 'fileutils'
|
3
|
+
include FileUtils
|
4
|
+
|
5
|
+
# path to your application root.
|
6
|
+
APP_ROOT = File.expand_path('..', __dir__)
|
7
|
+
|
8
|
+
def system!(*args)
|
9
|
+
system(*args) || abort("\n== Command #{args} failed ==")
|
10
|
+
end
|
11
|
+
|
12
|
+
chdir APP_ROOT do
|
13
|
+
# This script is a way to update your development environment automatically.
|
14
|
+
# Add necessary update steps to this file.
|
15
|
+
|
16
|
+
puts '== Installing dependencies =='
|
17
|
+
system! 'gem install bundler --conservative'
|
18
|
+
system('bundle check') || system!('bundle install')
|
19
|
+
|
20
|
+
# Install JavaScript dependencies if using Yarn
|
21
|
+
# system('bin/yarn')
|
22
|
+
|
23
|
+
puts "\n== Updating database =="
|
24
|
+
system! 'bin/rails db:migrate'
|
25
|
+
|
26
|
+
puts "\n== Removing old logs and tempfiles =="
|
27
|
+
system! 'bin/rails log:clear tmp:clear'
|
28
|
+
|
29
|
+
puts "\n== Restarting application server =="
|
30
|
+
system! 'bin/rails restart'
|
31
|
+
end
|
data/bin/yarn
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
APP_ROOT = File.expand_path('..', __dir__)
|
3
|
+
Dir.chdir(APP_ROOT) do
|
4
|
+
yarn = ENV["PATH"].split(File::PATH_SEPARATOR).
|
5
|
+
select { |dir| File.expand_path(dir) != __dir__ }.
|
6
|
+
product(["yarn", "yarn.cmd", "yarn.ps1"]).
|
7
|
+
map { |dir, file| File.expand_path(file, dir) }.
|
8
|
+
find { |file| File.executable?(file) }
|
9
|
+
|
10
|
+
if yarn
|
11
|
+
exec yarn, *ARGV
|
12
|
+
else
|
13
|
+
$stderr.puts "Yarn executable was not detected in the system."
|
14
|
+
$stderr.puts "Download Yarn at https://yarnpkg.com/en/docs/install"
|
15
|
+
exit 1
|
16
|
+
end
|
17
|
+
end
|
data/config/application.rb
CHANGED
@@ -1,56 +1,38 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
1
|
+
require_relative "boot"
|
2
|
+
|
3
|
+
# Pick the frameworks you want:
|
4
|
+
require "active_model/railtie"
|
5
|
+
require "active_job/railtie"
|
6
|
+
require "active_record/railtie"
|
7
|
+
require "active_storage/engine"
|
8
|
+
require "action_controller/railtie"
|
9
|
+
require "action_mailer/railtie"
|
10
|
+
require "action_mailbox/engine"
|
11
|
+
require "action_text/engine"
|
12
|
+
require "action_view/railtie"
|
13
|
+
require "action_cable/engine"
|
14
|
+
# require "sprockets/railtie"
|
15
|
+
require "rails/test_unit/railtie"
|
16
|
+
|
17
|
+
# Require the gems listed in Gemfile, including any gems
|
18
|
+
# you've limited to :test, :development, or :production.
|
19
|
+
Bundler.require(*Rails.groups)
|
11
20
|
|
12
21
|
module Iqvoc::Inflectionals
|
13
22
|
class Application < Rails::Application
|
23
|
+
# Initialize configuration defaults for originally generated Rails version.
|
24
|
+
config.load_defaults 7.0
|
25
|
+
|
26
|
+
# Configuration for the application, engines, and railties goes here.
|
27
|
+
#
|
28
|
+
# These settings can be overridden in specific environments using the files
|
29
|
+
# in config/environments, which are processed later.
|
30
|
+
#
|
31
|
+
# config.time_zone = "Central Time (US & Canada)"
|
32
|
+
# config.eager_load_paths << Rails.root.join("extras")
|
33
|
+
#
|
14
34
|
|
15
35
|
# This has to be here because iqvoc_inflectionals.rb needs to know if it runs as app or as engine
|
16
36
|
require 'iqvoc_inflectionals'
|
17
|
-
|
18
|
-
# Settings in config/environments/* take precedence over those specified here.
|
19
|
-
# Application configuration should go into files in config/initializers
|
20
|
-
# -- all .rb files in that directory are automatically loaded.
|
21
|
-
|
22
|
-
# Custom directories with classes and modules you want to be autoloadable.
|
23
|
-
# config.autoload_paths += %W(#{config.root}/extras)
|
24
|
-
|
25
|
-
# Only load the plugins named here, in the order given (default is alphabetical).
|
26
|
-
# :all can be used as a placeholder for all plugins not explicitly named.
|
27
|
-
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
28
|
-
|
29
|
-
# Activate observers that should always be running.
|
30
|
-
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
|
31
|
-
|
32
|
-
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
|
33
|
-
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
34
|
-
# config.time_zone = 'Central Time (US & Canada)'
|
35
|
-
|
36
|
-
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
37
|
-
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
38
|
-
config.i18n.default_locale = :de
|
39
|
-
# config.i18n.available_locales = [:de, :en]
|
40
|
-
|
41
|
-
# JavaScript files you want as :defaults (application.js is always included).
|
42
|
-
# config.action_view.javascript_expansions[:defaults] = %w(jquery rails)
|
43
|
-
|
44
|
-
# Configure the default encoding used in templates for Ruby 1.9.
|
45
|
-
config.encoding = "utf-8"
|
46
|
-
|
47
|
-
# Configure sensitive parameters which will be filtered from the log file.
|
48
|
-
config.filter_parameters += [:password, :password_confirmation]
|
49
|
-
|
50
|
-
# Enable the asset pipeline
|
51
|
-
config.assets.enabled = true
|
52
|
-
|
53
|
-
# Version of your assets, change this if you want to expire all your assets
|
54
|
-
config.assets.version = "1.0.0"
|
55
37
|
end
|
56
38
|
end
|
data/config/boot.rb
CHANGED
@@ -1,13 +1,4 @@
|
|
1
|
-
|
1
|
+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
|
2
2
|
|
3
|
-
# Set up gems listed in the Gemfile.
|
4
|
-
|
5
|
-
begin
|
6
|
-
ENV['BUNDLE_GEMFILE'] = gemfile
|
7
|
-
require 'bundler'
|
8
|
-
Bundler.setup
|
9
|
-
rescue Bundler::GemNotFound => e
|
10
|
-
STDERR.puts e.message
|
11
|
-
STDERR.puts "Try running `bundle install`."
|
12
|
-
exit!
|
13
|
-
end if File.exist?(gemfile)
|
3
|
+
require "bundler/setup" # Set up gems listed in the Gemfile.
|
4
|
+
require "bootsnap/setup" # Speed up boot time by caching expensive operations.
|
data/config/cable.yml
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
development:
|
2
|
+
adapter: postgresql
|
3
|
+
host: localhost
|
4
|
+
encoding: unicode
|
5
|
+
database: <%= ENV["POSTGRES_DB"] || 'iqvoc_inflectionals_development' %>
|
6
|
+
pool: 5
|
7
|
+
username: <%= ENV["POSTGRES_USER"] || 'postgres' %>
|
8
|
+
password: <%= ENV["POSTGRES_PASSWORD"] || 'postgres' %>
|
9
|
+
|
10
|
+
test:
|
11
|
+
adapter: postgresql
|
12
|
+
host: localhost
|
13
|
+
encoding: unicode
|
14
|
+
database: <%= ENV["POSTGRES_DB"] || 'iqvoc_inflectionals_test' %>
|
15
|
+
pool: 5
|
16
|
+
username: <%= ENV["POSTGRES_USER"] || 'postgres' %>
|
17
|
+
password: <%= ENV["POSTGRES_PASSWORD"] || 'postgres' %>
|
18
|
+
|
19
|
+
production:
|
20
|
+
adapter: postgresql
|
21
|
+
host: localhost
|
22
|
+
encoding: unicode
|
23
|
+
database: <%= ENV["POSTGRES_DB"] || 'iqvoc_inflectionals_production' %>
|
24
|
+
pool: 5
|
25
|
+
username: <%= ENV["POSTGRES_USER"] || 'postgres' %>
|
26
|
+
password: <%= ENV["POSTGRES_PASSWORD"] || 'postgres' %>
|
data/config/environment.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
# Load the Rails application
|
2
|
-
|
1
|
+
# Load the Rails application.
|
2
|
+
require_relative "application"
|
3
3
|
|
4
|
-
# Initialize the Rails application
|
5
|
-
|
4
|
+
# Initialize the Rails application.
|
5
|
+
Rails.application.initialize!
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Define an application-wide content security policy.
|
4
|
+
# See the Securing Rails Applications Guide for more information:
|
5
|
+
# https://guides.rubyonrails.org/security.html#content-security-policy-header
|
6
|
+
|
7
|
+
# Rails.application.configure do
|
8
|
+
# config.content_security_policy do |policy|
|
9
|
+
# policy.default_src :self, :https
|
10
|
+
# policy.font_src :self, :https, :data
|
11
|
+
# policy.img_src :self, :https, :data
|
12
|
+
# policy.object_src :none
|
13
|
+
# policy.script_src :self, :https
|
14
|
+
# policy.style_src :self, :https
|
15
|
+
# # Specify URI for violation reports
|
16
|
+
# # policy.report_uri "/csp-violation-report-endpoint"
|
17
|
+
# end
|
18
|
+
#
|
19
|
+
# # Generate session nonces for permitted importmap and inline scripts
|
20
|
+
# config.content_security_policy_nonce_generator = ->(request) { request.session.id.to_s }
|
21
|
+
# config.content_security_policy_nonce_directives = %w(script-src)
|
22
|
+
#
|
23
|
+
# # Report violations without enforcing the policy.
|
24
|
+
# # config.content_security_policy_report_only = true
|
25
|
+
# end
|
@@ -0,0 +1,8 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Configure parameters to be filtered from the log file. Use this to limit dissemination of
|
4
|
+
# sensitive information. See the ActiveSupport::ParameterFilter documentation for supported
|
5
|
+
# notations and behaviors.
|
6
|
+
Rails.application.config.filter_parameters += [
|
7
|
+
:passw, :secret, :token, :_key, :crypt, :salt, :certificate, :otp, :ssn
|
8
|
+
]
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Add new inflection rules using the following format. Inflections
|
4
|
+
# are locale specific, and you may define rules for as many different
|
5
|
+
# locales as you wish. All of these examples are active by default:
|
6
|
+
# ActiveSupport::Inflector.inflections(:en) do |inflect|
|
7
|
+
# inflect.plural /^(ox)$/i, "\\1en"
|
8
|
+
# inflect.singular /^(ox)en/i, "\\1"
|
9
|
+
# inflect.irregular "person", "people"
|
10
|
+
# inflect.uncountable %w( fish sheep )
|
11
|
+
# end
|
12
|
+
|
13
|
+
# These inflection rules are supported but not enabled by default:
|
14
|
+
# ActiveSupport::Inflector.inflections(:en) do |inflect|
|
15
|
+
# inflect.acronym "RESTful"
|
16
|
+
# end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# Define an application-wide HTTP permissions policy. For further
|
2
|
+
# information see https://developers.google.com/web/updates/2018/06/feature-policy
|
3
|
+
#
|
4
|
+
# Rails.application.config.permissions_policy do |f|
|
5
|
+
# f.camera :none
|
6
|
+
# f.gyroscope :none
|
7
|
+
# f.microphone :none
|
8
|
+
# f.usb :none
|
9
|
+
# f.fullscreen :self
|
10
|
+
# f.payment :self, "https://secure.example.com"
|
11
|
+
# end
|
data/config/storage.yml
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
test:
|
2
|
+
service: Disk
|
3
|
+
root: <%= Rails.root.join("tmp/storage") %>
|
4
|
+
|
5
|
+
local:
|
6
|
+
service: Disk
|
7
|
+
root: <%= Rails.root.join("storage") %>
|
8
|
+
|
9
|
+
# Use rails credentials:edit to set the AWS secrets (as aws:access_key_id|secret_access_key)
|
10
|
+
# amazon:
|
11
|
+
# service: S3
|
12
|
+
# access_key_id: <%= Rails.application.credentials.dig(:aws, :access_key_id) %>
|
13
|
+
# secret_access_key: <%= Rails.application.credentials.dig(:aws, :secret_access_key) %>
|
14
|
+
# region: us-east-1
|
15
|
+
# bucket: your_own_bucket
|
16
|
+
|
17
|
+
# Remember not to checkin your GCS keyfile to a repository
|
18
|
+
# google:
|
19
|
+
# service: GCS
|
20
|
+
# project: your_project
|
21
|
+
# credentials: <%= Rails.root.join("path/to/gcs.keyfile") %>
|
22
|
+
# bucket: your_own_bucket
|
23
|
+
|
24
|
+
# Use rails credentials:edit to set the Azure Storage secret (as azure_storage:storage_access_key)
|
25
|
+
# microsoft:
|
26
|
+
# service: AzureStorage
|
27
|
+
# storage_account_name: your_account_name
|
28
|
+
# storage_access_key: <%= Rails.application.credentials.dig(:azure_storage, :storage_access_key) %>
|
29
|
+
# container: your_container_name
|
30
|
+
|
31
|
+
# mirror:
|
32
|
+
# service: Mirror
|
33
|
+
# primary: local
|
34
|
+
# mirrors: [ amazon, google, microsoft ]
|
data/config.ru
CHANGED
@@ -1,4 +1,6 @@
|
|
1
1
|
# This file is used by Rack-based servers to start the application.
|
2
2
|
|
3
|
-
|
4
|
-
|
3
|
+
require_relative "config/environment"
|
4
|
+
|
5
|
+
run Rails.application
|
6
|
+
Rails.application.load_server
|
@@ -1,4 +1,4 @@
|
|
1
|
-
class AddInflectionalAttributesToLabel < ActiveRecord::Migration
|
1
|
+
class AddInflectionalAttributesToLabel < ActiveRecord::Migration[4.2]
|
2
2
|
def change
|
3
3
|
add_column :labels, :base_form, :string unless column_exists?(:labels, :base_form)
|
4
4
|
add_column :labels, :inflectional_code, :string unless column_exists?(:labels, :inflectional_code)
|
@@ -1,4 +1,4 @@
|
|
1
|
-
class ChangeInflectionalValueCollation < ActiveRecord::Migration
|
1
|
+
class ChangeInflectionalValueCollation < ActiveRecord::Migration[4.2]
|
2
2
|
def up
|
3
3
|
if ActiveRecord::Base.connection.adapter_name == 'Mysql2'
|
4
4
|
execute("ALTER TABLE inflectionals MODIFY value varchar(4000) CHARACTER SET utf8 COLLATE utf8_bin;")
|
data/faucet.config.js
ADDED
@@ -0,0 +1,46 @@
|
|
1
|
+
module.exports = {
|
2
|
+
js: [
|
3
|
+
{
|
4
|
+
source: "./node_modules/jquery/dist/jquery.js",
|
5
|
+
target: "./public/assets/javascripts/jquery.js",
|
6
|
+
exports: "jQuery",
|
7
|
+
compact: "mangle"
|
8
|
+
},
|
9
|
+
{
|
10
|
+
source: "./app/assets/javascripts/manifest.js",
|
11
|
+
target: "./public/assets/javascripts/manifest.js",
|
12
|
+
externals: { jquery: "jQuery" },
|
13
|
+
},
|
14
|
+
{
|
15
|
+
source: "./node_modules/bootstrap/dist/js/bootstrap.bundle.min.js",
|
16
|
+
target: "./public/assets/javascripts/bootstrap.bundle.min.js",
|
17
|
+
externals: { jquery: "jQuery" },
|
18
|
+
compact: "minify"
|
19
|
+
}
|
20
|
+
],
|
21
|
+
sass: [{
|
22
|
+
source: "./app/assets/stylesheets/manifest.scss",
|
23
|
+
target: "./public/assets/stylesheets/manifest.css"
|
24
|
+
}],
|
25
|
+
static: [
|
26
|
+
{
|
27
|
+
source: "./node_modules/iqvoc/app/assets/images",
|
28
|
+
target: "./public/assets/images"
|
29
|
+
},
|
30
|
+
{
|
31
|
+
source: "./node_modules/iqvoc/app/assets/fonts",
|
32
|
+
target: "./public/assets/fonts"
|
33
|
+
},
|
34
|
+
{
|
35
|
+
source: "./node_modules/font-awesome/fonts",
|
36
|
+
target: "./public/assets/fonts",
|
37
|
+
fingerprint: false
|
38
|
+
}
|
39
|
+
],
|
40
|
+
manifest: {
|
41
|
+
target: "./public/assets/manifest.json",
|
42
|
+
key: "short",
|
43
|
+
webRoot: "./public"
|
44
|
+
},
|
45
|
+
watchDirs: ["./app/assets"]
|
46
|
+
};
|
data/iqvoc_inflectionals.gemspec
CHANGED
@@ -15,8 +15,8 @@ Gem::Specification.new do |s|
|
|
15
15
|
|
16
16
|
s.rubyforge_project = 'iqvoc_inflectionals'
|
17
17
|
|
18
|
-
s.add_dependency 'iqvoc', '
|
19
|
-
s.add_dependency 'iqvoc_skosxl', '~> 2.
|
18
|
+
s.add_dependency 'iqvoc', '~> 4.14.4'
|
19
|
+
s.add_dependency 'iqvoc_skosxl', '~> 2.11.3'
|
20
20
|
|
21
21
|
s.files = `git ls-files`.split("\n")
|
22
22
|
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|