This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ActiveRecord::Base.logger = Rails.logger = ActiveSupport::TaggedLogging.new(Logger.new(STDOUT)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class SidekiqQueue < Sidekiq::Queue | |
| def newer(limit = 1) | |
| fetch_one_or_more_jobs(starting: :back, limit: limit) | |
| end | |
| def older(limit = 1) | |
| fetch_one_or_more_jobs(starting: :front, limit: limit) | |
| end | |
| def all |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Note: Add the uncommented lines inside the Application class definition inside application.rb file | |
| # [...] | |
| # class XYZ < Rails::Application | |
| if Rails.env == 'test' | |
| require 'diagnostic' | |
| config.middleware.use(::Diagnostic) | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $.grep(VisualEvent.instance.s.elements, function(e) { return e.node == $('JQUERY_SELECTOR')[0] }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| unless Rails.env.development? || Rails.env.test? | |
| YourApplication::Application.configure do |config| | |
| config.middleware.insert_after(::Rack::Lock, "::Rack::Auth::Basic", "Application Name") do |u, p| | |
| [u, p] == [ENV['HTTP_USER'], ENV['HTTP_PASSWORD']] | |
| end | |
| end | |
| end |
NewerOlder