I hereby claim:
- I am gary on github.
- I am giams (https://keybase.io/giams) on keybase.
- I have a public key ASCHZYrVj4BBeaCo8zT14xUw7z2xiq7SZYbhusDYCI1_Lwo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
| From 4474caab21f80a2c5e0ba6af3dd1465a19ce1378 Mon Sep 17 00:00:00 2001 | |
| From: Gary Iams <[email protected]> | |
| Date: Thu, 16 Jun 2016 19:27:25 -0400 | |
| Subject: [PATCH] Quick 'n dirty solution for reducing logging noise | |
| - Disable NewRelic. Reporting issues instrumenting the AssetsController. | |
| - Fix how VipsProcessor constant is referenced in the AssetsController | |
| - Ignore the response code from Image#destroy_file!'s WebDAV request | |
| --- | |
| api/app/controllers/assets_controller.rb | 8 ++++---- |
| open(url) { |channel| JSON.parse(channel.read) }.map do |channel_data| | |
| attrs = channel_data.values_at("id", "key", "name", "description", | |
| "asset_url", "created_at", "updated_at") | |
| Channel.new(*attrs).tap(&:pick_stream_url) | |
| end | |
| # => #<Enumerator: [{"json"=>"attrs"}, { "json"=> "attrs"},{"json"=>"attrs"}]:map> | |
| open(url) { |channel| JSON.parse(channel.read) }.map { |channel_data| | |
| attrs = channel_data.values_at("id", "key", "name", "description", | |
| "asset_url", "created_at", "updated_at") |
| From emacs |
| if ENV['HEADLESS'] | |
| require 'headless' | |
| headless = Headless.new | |
| headless.start | |
| at_exit { headless.destroy } | |
| end |
| #!/usr/bin/env ruby -w | |
| require 'request_log_analyzer' | |
| # for use with wvanbergen/request-log-analyzer | |
| class NginxRequestTimeFormat < RequestLogAnalyzer::FileFormat::Nginx | |
| line_definition :current_request_time do |line| | |
| line.captures << { :name => :request_time, :type => :msec } | |
| line.regexp = %r|- (\d+.\d+)$| |
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>KeepAlive</key> | |
| <false/> | |
| <key>Label</key> | |
| <string>org.gnu.emacsd</string> | |
| <key>ProgramArguments</key> | |
| <array> |
| machine api.github.com | |
| login # your GitHub username | |
| password # your GitHub password |
+-------------------+ +-------------------+ | Black Box Testing | | White Box Testing | +-------------------+ +-------------------+
| class people::gary { | |
| include osx::global::key_repeat_rate | |
| class { 'osx::global::key_repeat_delay': | |
| delay => 10 | |
| } | |
| # no sudo prompt or error notification | |
| # FIXME: | |
| exec { 'hotfix for shitty osx 10.8 defaults': | |
| command => "/Users/${::boxen_user}/bin/apply-osx-defaults.sh", |