simple_calendar 3.0.3 → 3.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (93) hide show
  1. checksums.yaml +4 -4
  2. data/lib/simple_calendar/version.rb +1 -1
  3. metadata +8 -97
  4. data/.github/FUNDING.yml +0 -12
  5. data/.github/workflows/ci.yml +0 -45
  6. data/.github/workflows/publish_gem.yml +0 -22
  7. data/.gitignore +0 -10
  8. data/.rspec +0 -2
  9. data/.standard.yml +0 -1
  10. data/Appraisals +0 -15
  11. data/CHANGELOG.md +0 -39
  12. data/Gemfile +0 -11
  13. data/Gemfile.lock +0 -258
  14. data/LICENSE.txt +0 -22
  15. data/bin/console +0 -8
  16. data/bin/rails +0 -16
  17. data/bin/setup +0 -5
  18. data/gemfiles/rails_6_1.gemfile +0 -12
  19. data/gemfiles/rails_6_1.gemfile.lock +0 -234
  20. data/gemfiles/rails_7_0.gemfile +0 -12
  21. data/gemfiles/rails_7_0.gemfile.lock +0 -231
  22. data/gemfiles/rails_7_1.gemfile +0 -12
  23. data/gemfiles/rails_7_1.gemfile.lock +0 -264
  24. data/gemfiles/rails_main.gemfile +0 -12
  25. data/gemfiles/rails_main.gemfile.lock +0 -263
  26. data/simple_calendar.gemspec +0 -20
  27. data/test/calendars/calendar_test.rb +0 -161
  28. data/test/calendars/month_calendar_test.rb +0 -16
  29. data/test/dummy/Rakefile +0 -6
  30. data/test/dummy/app/assets/config/manifest.js +0 -1
  31. data/test/dummy/app/assets/images/.keep +0 -0
  32. data/test/dummy/app/assets/stylesheets/application.css +0 -1
  33. data/test/dummy/app/calendars/business_week_calendar.rb +0 -9
  34. data/test/dummy/app/channels/application_cable/channel.rb +0 -4
  35. data/test/dummy/app/channels/application_cable/connection.rb +0 -4
  36. data/test/dummy/app/controllers/application_controller.rb +0 -2
  37. data/test/dummy/app/controllers/concerns/.keep +0 -0
  38. data/test/dummy/app/controllers/meetings_controller.rb +0 -63
  39. data/test/dummy/app/helpers/application_helper.rb +0 -2
  40. data/test/dummy/app/helpers/meetings_helper.rb +0 -2
  41. data/test/dummy/app/jobs/application_job.rb +0 -7
  42. data/test/dummy/app/mailers/application_mailer.rb +0 -4
  43. data/test/dummy/app/models/application_record.rb +0 -7
  44. data/test/dummy/app/models/concerns/.keep +0 -0
  45. data/test/dummy/app/models/meeting.rb +0 -2
  46. data/test/dummy/app/views/layouts/application.html.erb +0 -15
  47. data/test/dummy/app/views/layouts/mailer.html.erb +0 -13
  48. data/test/dummy/app/views/layouts/mailer.text.erb +0 -1
  49. data/test/dummy/app/views/meetings/_business_week_calendar.html.erb +0 -33
  50. data/test/dummy/app/views/meetings/_form.html.erb +0 -32
  51. data/test/dummy/app/views/meetings/_meeting.html.erb +0 -17
  52. data/test/dummy/app/views/meetings/business_week.html.erb +0 -24
  53. data/test/dummy/app/views/meetings/edit.html.erb +0 -10
  54. data/test/dummy/app/views/meetings/index.html.erb +0 -24
  55. data/test/dummy/app/views/meetings/new.html.erb +0 -9
  56. data/test/dummy/app/views/meetings/show.html.erb +0 -10
  57. data/test/dummy/bin/rails +0 -4
  58. data/test/dummy/bin/rake +0 -4
  59. data/test/dummy/bin/setup +0 -33
  60. data/test/dummy/config/application.rb +0 -22
  61. data/test/dummy/config/boot.rb +0 -5
  62. data/test/dummy/config/cable.yml +0 -10
  63. data/test/dummy/config/database.yml +0 -25
  64. data/test/dummy/config/environment.rb +0 -5
  65. data/test/dummy/config/environments/development.rb +0 -67
  66. data/test/dummy/config/environments/production.rb +0 -87
  67. data/test/dummy/config/environments/test.rb +0 -60
  68. data/test/dummy/config/initializers/content_security_policy.rb +0 -25
  69. data/test/dummy/config/initializers/filter_parameter_logging.rb +0 -8
  70. data/test/dummy/config/initializers/inflections.rb +0 -16
  71. data/test/dummy/config/initializers/permissions_policy.rb +0 -11
  72. data/test/dummy/config/locales/en.yml +0 -33
  73. data/test/dummy/config/puma.rb +0 -43
  74. data/test/dummy/config/routes.rb +0 -11
  75. data/test/dummy/config/storage.yml +0 -34
  76. data/test/dummy/config.ru +0 -6
  77. data/test/dummy/db/migrate/20220930184313_create_meetings.rb +0 -11
  78. data/test/dummy/db/schema.rb +0 -21
  79. data/test/dummy/lib/assets/.keep +0 -0
  80. data/test/dummy/log/.keep +0 -0
  81. data/test/dummy/public/404.html +0 -67
  82. data/test/dummy/public/422.html +0 -67
  83. data/test/dummy/public/500.html +0 -66
  84. data/test/dummy/public/apple-touch-icon-precomposed.png +0 -0
  85. data/test/dummy/public/apple-touch-icon.png +0 -0
  86. data/test/dummy/public/favicon.ico +0 -0
  87. data/test/dummy/storage/.keep +0 -0
  88. data/test/fixtures/meetings.yml +0 -36
  89. data/test/integrations/custom_calendar_test.rb +0 -33
  90. data/test/integrations/month_calendar_test.rb +0 -58
  91. data/test/simple_calendar_test.rb +0 -7
  92. data/test/test_helper.rb +0 -17
  93. /data/app/assets/stylesheets/{simple_calendar.scss → simple_calendar.css} +0 -0
@@ -1,16 +0,0 @@
1
- require "test_helper"
2
-
3
- class MonthCalendarTest < ActionView::TestCase
4
- test "date_range returns a full calendar month" do
5
- today = Date.today
6
- calendar = SimpleCalendar::MonthCalendar.new(view, start_date: today)
7
- assert calendar.date_range.min <= today.beginning_of_month
8
- assert calendar.date_range.max >= today.end_of_month
9
- end
10
-
11
- test "date_range returns the days of next and previous months on the edges of the calendar" do
12
- calendar = SimpleCalendar::MonthCalendar.new(view, start_date: Date.new(2018, 8, 1))
13
- assert_equal Date.new(2018, 7, 30), calendar.date_range.first
14
- assert_equal Date.new(2018, 9, 2), calendar.date_range.last
15
- end
16
- end
data/test/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_relative "config/application"
5
-
6
- Rails.application.load_tasks
@@ -1 +0,0 @@
1
- //= link_directory ../stylesheets
File without changes
@@ -1 +0,0 @@
1
- /* Application styles */
@@ -1,9 +0,0 @@
1
- class BusinessWeekCalendar < SimpleCalendar::Calendar
2
- private
3
-
4
- def date_range
5
- beginning = start_date.monday
6
- ending = beginning + 5.days
7
- (beginning..ending).to_a
8
- end
9
- end
@@ -1,4 +0,0 @@
1
- module ApplicationCable
2
- class Channel < ActionCable::Channel::Base
3
- end
4
- end
@@ -1,4 +0,0 @@
1
- module ApplicationCable
2
- class Connection < ActionCable::Connection::Base
3
- end
4
- end
@@ -1,2 +0,0 @@
1
- class ApplicationController < ActionController::Base
2
- end
File without changes
@@ -1,63 +0,0 @@
1
- class MeetingsController < ApplicationController
2
- before_action :set_meeting, only: %i[show edit update destroy]
3
-
4
- # GET /meetings
5
- def index
6
- @meetings = Meeting.all
7
- end
8
-
9
- def business_week
10
- @meetings = Meeting.all
11
- end
12
-
13
- # GET /meetings/1
14
- def show
15
- end
16
-
17
- # GET /meetings/new
18
- def new
19
- @meeting = Meeting.new
20
- end
21
-
22
- # GET /meetings/1/edit
23
- def edit
24
- end
25
-
26
- # POST /meetings
27
- def create
28
- @meeting = Meeting.new(meeting_params)
29
-
30
- if @meeting.save
31
- redirect_to @meeting, notice: "Meeting was successfully created."
32
- else
33
- render :new, status: :unprocessable_entity
34
- end
35
- end
36
-
37
- # PATCH/PUT /meetings/1
38
- def update
39
- if @meeting.update(meeting_params)
40
- redirect_to @meeting, notice: "Meeting was successfully updated."
41
- else
42
- render :edit, status: :unprocessable_entity
43
- end
44
- end
45
-
46
- # DELETE /meetings/1
47
- def destroy
48
- @meeting.destroy
49
- redirect_to meetings_url, notice: "Meeting was successfully destroyed."
50
- end
51
-
52
- private
53
-
54
- # Use callbacks to share common setup or constraints between actions.
55
- def set_meeting
56
- @meeting = Meeting.find(params[:id])
57
- end
58
-
59
- # Only allow a list of trusted parameters through.
60
- def meeting_params
61
- params.require(:meeting).permit(:name, :start_time, :end_time)
62
- end
63
- end
@@ -1,2 +0,0 @@
1
- module ApplicationHelper
2
- end
@@ -1,2 +0,0 @@
1
- module MeetingsHelper
2
- end
@@ -1,7 +0,0 @@
1
- class ApplicationJob < ActiveJob::Base
2
- # Automatically retry jobs that encountered a deadlock
3
- # retry_on ActiveRecord::Deadlocked
4
-
5
- # Most jobs are safe to ignore if the underlying records are no longer available
6
- # discard_on ActiveJob::DeserializationError
7
- end
@@ -1,4 +0,0 @@
1
- class ApplicationMailer < ActionMailer::Base
2
- default from: "from@example.com"
3
- layout "mailer"
4
- end
@@ -1,7 +0,0 @@
1
- class ApplicationRecord < ActiveRecord::Base
2
- if Rails.gem_version >= Gem::Version.new("7.0")
3
- primary_abstract_class
4
- else
5
- self.abstract_class = true
6
- end
7
- end
File without changes
@@ -1,2 +0,0 @@
1
- class Meeting < ApplicationRecord
2
- end
@@ -1,15 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <title>Dummy</title>
5
- <meta name="viewport" content="width=device-width,initial-scale=1">
6
- <%= csrf_meta_tags %>
7
- <%= csp_meta_tag %>
8
-
9
- <%= stylesheet_link_tag "application" %>
10
- </head>
11
-
12
- <body>
13
- <%= yield %>
14
- </body>
15
- </html>
@@ -1,13 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
- <style>
6
- /* Email styles need to be inline */
7
- </style>
8
- </head>
9
-
10
- <body>
11
- <%= yield %>
12
- </body>
13
- </html>
@@ -1 +0,0 @@
1
- <%= yield %>
@@ -1,33 +0,0 @@
1
- <div class="simple-calendar">
2
- <div class="calendar-heading">
3
- <span class="calendar-title"><%= t('date.month_names')[start_date.month] %> <%= start_date.year %></span>
4
-
5
- <nav>
6
- <%= link_to t('simple_calendar.previous', default: 'Previous'), calendar.url_for_previous_view %>
7
- <%= link_to t('simple_calendar.today', default: 'Today'), calendar.url_for_today_view %>
8
- <%= link_to t('simple_calendar.next', default: 'Next'), calendar.url_for_next_view %>
9
- </nav>
10
- </div>
11
-
12
- <table class="table table-striped">
13
- <thead>
14
- <tr>
15
- <% date_range.slice(0, 7).each do |day| %>
16
- <th><%= t('date.abbr_day_names')[day.wday] %></th>
17
- <% end %>
18
- </tr>
19
- </thead>
20
-
21
- <tbody>
22
- <% date_range.each_slice(7) do |week| %>
23
- <%= content_tag :tr, class: calendar.tr_classes_for(week) do %>
24
- <% week.each do |day| %>
25
- <%= content_tag :td, class: calendar.td_classes_for(day) do %>
26
- <% instance_exec(day, calendar.sorted_events_for(day), &passed_block) %>
27
- <% end %>
28
- <% end %>
29
- <% end %>
30
- <% end %>
31
- </tbody>
32
- </table>
33
- </div>
@@ -1,32 +0,0 @@
1
- <%= form_with(model: meeting) do |form| %>
2
- <% if meeting.errors.any? %>
3
- <div style="color: red">
4
- <h2><%= pluralize(meeting.errors.count, "error") %> prohibited this meeting from being saved:</h2>
5
-
6
- <ul>
7
- <% meeting.errors.each do |error| %>
8
- <li><%= error.full_message %></li>
9
- <% end %>
10
- </ul>
11
- </div>
12
- <% end %>
13
-
14
- <div>
15
- <%= form.label :name, style: "display: block" %>
16
- <%= form.text_field :name %>
17
- </div>
18
-
19
- <div>
20
- <%= form.label :start_time, style: "display: block" %>
21
- <%= form.datetime_field :start_time %>
22
- </div>
23
-
24
- <div>
25
- <%= form.label :end_time, style: "display: block" %>
26
- <%= form.datetime_field :end_time %>
27
- </div>
28
-
29
- <div>
30
- <%= form.submit %>
31
- </div>
32
- <% end %>
@@ -1,17 +0,0 @@
1
- <div id="<%= dom_id meeting %>">
2
- <p>
3
- <strong>Name:</strong>
4
- <%= meeting.name %>
5
- </p>
6
-
7
- <p>
8
- <strong>Start time:</strong>
9
- <%= meeting.start_time %>
10
- </p>
11
-
12
- <p>
13
- <strong>End time:</strong>
14
- <%= meeting.end_time %>
15
- </p>
16
-
17
- </div>
@@ -1,24 +0,0 @@
1
- <p style="color: green"><%= notice %></p>
2
-
3
- <h1>Meetings</h1>
4
- <%= render BusinessWeekCalendar.new(self, events: @meetings) do |date, meetings| %>
5
- <%= date %>
6
-
7
- <% meetings.each do |meeting| %>
8
- <div>
9
- <%= meeting.name %>
10
- </div>
11
- <% end %>
12
- <% end %>
13
-
14
- <div id="meetings">
15
- <% @meetings.each do |meeting| %>
16
- <%= render meeting %>
17
- <p>
18
- <%= link_to "Show this meeting", meeting %>
19
- </p>
20
- <% end %>
21
- </div>
22
-
23
- <%= link_to "New meeting", new_meeting_path %>
24
- <%= Time.current.beginning_of_month %>
@@ -1,10 +0,0 @@
1
- <h1>Editing meeting</h1>
2
-
3
- <%= render "form", meeting: @meeting %>
4
-
5
- <br>
6
-
7
- <div>
8
- <%= link_to "Show this meeting", @meeting %> |
9
- <%= link_to "Back to meetings", meetings_path %>
10
- </div>
@@ -1,24 +0,0 @@
1
- <p style="color: green"><%= notice %></p>
2
-
3
- <h1>Meetings</h1>
4
- <%= month_calendar(events: @meetings) do |date, meetings| %>
5
- <%= date %>
6
-
7
- <% meetings.each do |meeting| %>
8
- <div>
9
- <%= meeting.name %>
10
- </div>
11
- <% end %>
12
- <% end %>
13
-
14
- <div id="meetings">
15
- <% @meetings.each do |meeting| %>
16
- <%= render meeting %>
17
- <p>
18
- <%= link_to "Show this meeting", meeting %>
19
- </p>
20
- <% end %>
21
- </div>
22
-
23
- <%= link_to "New meeting", new_meeting_path %>
24
- <%= Time.current.beginning_of_month %>
@@ -1,9 +0,0 @@
1
- <h1>New meeting</h1>
2
-
3
- <%= render "form", meeting: @meeting %>
4
-
5
- <br>
6
-
7
- <div>
8
- <%= link_to "Back to meetings", meetings_path %>
9
- </div>
@@ -1,10 +0,0 @@
1
- <p style="color: green"><%= notice %></p>
2
-
3
- <%= render @meeting %>
4
-
5
- <div>
6
- <%= link_to "Edit this meeting", edit_meeting_path(@meeting) %> |
7
- <%= link_to "Back to meetings", meetings_path %>
8
-
9
- <%= button_to "Destroy this meeting", @meeting, method: :delete %>
10
- </div>
data/test/dummy/bin/rails DELETED
@@ -1,4 +0,0 @@
1
- #!/usr/bin/env ruby
2
- APP_PATH = File.expand_path("../config/application", __dir__)
3
- require_relative "../config/boot"
4
- require "rails/commands"
data/test/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/test/dummy/bin/setup DELETED
@@ -1,33 +0,0 @@
1
- #!/usr/bin/env ruby
2
- require "fileutils"
3
-
4
- # path to your application root.
5
- APP_ROOT = File.expand_path("..", __dir__)
6
-
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.
15
-
16
- puts "== Installing dependencies =="
17
- system! "gem install bundler --conservative"
18
- system("bundle check") || system!("bundle install")
19
-
20
- # puts "\n== Copying sample files =="
21
- # unless File.exist?("config/database.yml")
22
- # FileUtils.cp "config/database.yml.sample", "config/database.yml"
23
- # end
24
-
25
- puts "\n== Preparing database =="
26
- system! "bin/rails db:prepare"
27
-
28
- puts "\n== Removing old logs and tempfiles =="
29
- system! "bin/rails log:clear tmp:clear"
30
-
31
- puts "\n== Restarting application server =="
32
- system! "bin/rails restart"
33
- end
@@ -1,22 +0,0 @@
1
- require_relative "boot"
2
-
3
- require "rails/all"
4
-
5
- # Require the gems listed in Gemfile, including any gems
6
- # you've limited to :test, :development, or :production.
7
- Bundler.require(*Rails.groups)
8
- require "simple_calendar"
9
-
10
- module Dummy
11
- class Application < Rails::Application
12
- config.load_defaults Rails::VERSION::STRING.to_f
13
-
14
- # Configuration for the application, engines, and railties goes here.
15
- #
16
- # These settings can be overridden in specific environments using the files
17
- # in config/environments, which are processed later.
18
- #
19
- # config.time_zone = "Central Time (US & Canada)"
20
- # config.eager_load_paths << Rails.root.join("extras")
21
- end
22
- end
@@ -1,5 +0,0 @@
1
- # Set up gems listed in the Gemfile.
2
- ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../../Gemfile", __dir__)
3
-
4
- require "bundler/setup" if File.exist?(ENV["BUNDLE_GEMFILE"])
5
- $LOAD_PATH.unshift File.expand_path("../../../lib", __dir__)
@@ -1,10 +0,0 @@
1
- development:
2
- adapter: async
3
-
4
- test:
5
- adapter: test
6
-
7
- production:
8
- adapter: redis
9
- url: <%= ENV.fetch("REDIS_URL") { "redis://localhost:6379/1" } %>
10
- channel_prefix: dummy_production
@@ -1,25 +0,0 @@
1
- # SQLite. Versions 3.8.0 and up are supported.
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: <%= ENV.fetch("RAILS_MAX_THREADS") { 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_relative "application"
3
-
4
- # Initialize the Rails application.
5
- Rails.application.initialize!
@@ -1,67 +0,0 @@
1
- require "active_support/core_ext/integer/time"
2
-
3
- Rails.application.configure do
4
- # Settings specified here will take precedence over those in config/application.rb.
5
-
6
- # In the development environment your application's code is reloaded any time
7
- # it changes. This slows down response time but is perfect for development
8
- # since you don't have to restart the web server when you make code changes.
9
- config.cache_classes = false
10
-
11
- # Do not eager load code on boot.
12
- config.eager_load = false
13
-
14
- # Show full error reports.
15
- config.consider_all_requests_local = true
16
-
17
- # Enable server timing
18
- config.server_timing = true
19
-
20
- # Enable/disable caching. By default caching is disabled.
21
- # Run rails dev:cache to toggle caching.
22
- if Rails.root.join("tmp/caching-dev.txt").exist?
23
- config.action_controller.perform_caching = true
24
- config.action_controller.enable_fragment_cache_logging = true
25
-
26
- config.cache_store = :memory_store
27
- config.public_file_server.headers = {
28
- "Cache-Control" => "public, max-age=#{2.days.to_i}"
29
- }
30
- else
31
- config.action_controller.perform_caching = false
32
-
33
- config.cache_store = :null_store
34
- end
35
-
36
- # Store uploaded files on the local file system (see config/storage.yml for options).
37
- config.active_storage.service = :local
38
-
39
- # Don't care if the mailer can't send.
40
- config.action_mailer.raise_delivery_errors = false
41
-
42
- config.action_mailer.perform_caching = false
43
-
44
- # Print deprecation notices to the Rails logger.
45
- config.active_support.deprecation = :log
46
-
47
- # Raise exceptions for disallowed deprecations.
48
- config.active_support.disallowed_deprecation = :raise
49
-
50
- # Tell Active Support which deprecation messages to disallow.
51
- config.active_support.disallowed_deprecation_warnings = []
52
-
53
- # Raise an error on page load if there are pending migrations.
54
- config.active_record.migration_error = :page_load
55
-
56
- # Highlight code that triggered database queries in logs.
57
- config.active_record.verbose_query_logs = true
58
-
59
- # Raises error for missing translations.
60
- # config.i18n.raise_on_missing_translations = true
61
-
62
- # Annotate rendered view with file names.
63
- # config.action_view.annotate_rendered_view_with_filenames = true
64
-
65
- # Uncomment if you wish to allow Action Cable access from any origin.
66
- # config.action_cable.disable_request_forgery_protection = true
67
- end
@@ -1,87 +0,0 @@
1
- require "active_support/core_ext/integer/time"
2
-
3
- Rails.application.configure do
4
- # Settings specified here will take precedence over those in config/application.rb.
5
-
6
- # Code is not reloaded between requests.
7
- config.cache_classes = true
8
-
9
- # Eager load code on boot. This eager loads most of Rails and
10
- # your application in memory, allowing both threaded web servers
11
- # and those relying on copy on write to perform better.
12
- # Rake tasks automatically ignore this option for performance.
13
- config.eager_load = true
14
-
15
- # Full error reports are disabled and caching is turned on.
16
- config.consider_all_requests_local = false
17
- config.action_controller.perform_caching = true
18
-
19
- # Ensures that a master key has been made available in either ENV["RAILS_MASTER_KEY"]
20
- # or in config/master.key. This key is used to decrypt credentials (and other encrypted files).
21
- # config.require_master_key = true
22
-
23
- # Disable serving static files from the `/public` folder by default since
24
- # Apache or NGINX already handles this.
25
- config.public_file_server.enabled = ENV["RAILS_SERVE_STATIC_FILES"].present?
26
-
27
- # Enable serving of images, stylesheets, and JavaScripts from an asset server.
28
- # config.asset_host = "http://assets.example.com"
29
-
30
- # Specifies the header that your server uses for sending files.
31
- # config.action_dispatch.x_sendfile_header = "X-Sendfile" # for Apache
32
- # config.action_dispatch.x_sendfile_header = "X-Accel-Redirect" # for NGINX
33
-
34
- # Store uploaded files on the local file system (see config/storage.yml for options).
35
- config.active_storage.service = :local
36
-
37
- # Mount Action Cable outside main process or domain.
38
- # config.action_cable.mount_path = nil
39
- # config.action_cable.url = "wss://example.com/cable"
40
- # config.action_cable.allowed_request_origins = [ "http://example.com", /http:\/\/example.*/ ]
41
-
42
- # Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
43
- # config.force_ssl = true
44
-
45
- # Include generic and useful information about system operation, but avoid logging too much
46
- # information to avoid inadvertent exposure of personally identifiable information (PII).
47
- config.log_level = :info
48
-
49
- # Prepend all log lines with the following tags.
50
- config.log_tags = [:request_id]
51
-
52
- # Use a different cache store in production.
53
- # config.cache_store = :mem_cache_store
54
-
55
- # Use a real queuing backend for Active Job (and separate queues per environment).
56
- # config.active_job.queue_adapter = :resque
57
- # config.active_job.queue_name_prefix = "dummy_production"
58
-
59
- config.action_mailer.perform_caching = false
60
-
61
- # Ignore bad email addresses and do not raise email delivery errors.
62
- # Set this to true and configure the email server for immediate delivery to raise delivery errors.
63
- # config.action_mailer.raise_delivery_errors = false
64
-
65
- # Enable locale fallbacks for I18n (makes lookups for any locale fall back to
66
- # the I18n.default_locale when a translation cannot be found).
67
- config.i18n.fallbacks = true
68
-
69
- # Don't log any deprecations.
70
- config.active_support.report_deprecations = false
71
-
72
- # Use default logging formatter so that PID and timestamp are not suppressed.
73
- config.log_formatter = ::Logger::Formatter.new
74
-
75
- # Use a different logger for distributed setups.
76
- # require "syslog/logger"
77
- # config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new "app-name")
78
-
79
- if ENV["RAILS_LOG_TO_STDOUT"].present?
80
- logger = ActiveSupport::Logger.new($stdout)
81
- logger.formatter = config.log_formatter
82
- config.logger = ActiveSupport::TaggedLogging.new(logger)
83
- end
84
-
85
- # Do not dump schema after migrations.
86
- config.active_record.dump_schema_after_migration = false
87
- end