I hereby claim:
- I am ngelx on github.
- I am ngel (https://keybase.io/ngel) on keybase.
- I have a public key ASDRGl-sWVIho9RL_FVJ2lmQ4vZrALt3SOU_ZfpsZIqgrQo
To claim this, I am signing this object:
The problem is this: | |
class Cmr < ActiveRecord::Base | |
belongs_to :ruta | |
... | |
end | |
class Cmr24 < Cmr | |
... | |
end | |
class Ruta < ActiveRecord::Base |
I hereby claim:
To claim this, I am signing this object:
# config/initializer/query_track.rb | |
# query_track: https://github.com/kirillshevch/query_track | |
# rollbar: https://docs.rollbar.com/docs/rails | |
QueryTrack::Settings.configure do |config| | |
config.duration = 1 # in seconds | |
config.notifications.custom_handler = lambda do |sql, duration, trace| | |
e = Exception.new("Slow SQL Query - #{trace}") |
# Install `dnsmasq` and configure for *.local and *.localhost domains | |
$ brew install dnsmasq | |
$ vim /opt/homebrew/etc/dnsmasq.conf | |
# Stop and restart service as root. | |
$ brew services stop dnsmasq | |
$ sudo brew services start dnsmasq | |
$ dscacheutil -flushcache |
# Strictly adhere to email address standards and disallow hyphens at the beginning or end of the domain name. | |
# Use https://rubular.com for live testing. | |
def validate_email(string) | |
(string.downcase =~ /\A[a-zA-Z0-9._%+-]+@[a-zA-Z0-9](?:[a-zA-Z0-9\-_]*[a-zA-Z0-9])?(?:\.[a-zA-Z0-9]*)(?:\.[a-zA-Z]{2,})+\z/)&.zero? | |
end |
This is an ActiveAdmin extension to add the interface to handle rails-setting-cached v2. For prior version I was using activeadmin_setting_cached but seems to be dead and does not support version > 2.
The initial idea was to extend that gem and do a PR, but the code is quite old and probably overcomplex. I may move this to a simple gem if there is any intereset on it.
Just place the files in the proper places and should be ready to go.