This gist was moved to its own repo to allow contributions: https://github.com/danguita/osx-for-developers. Feel free to pull request!
module Where | |
class <<self | |
attr_accessor :editor | |
def is_proc(proc) | |
source_location(proc) | |
end | |
def is_method(klass, method_name) | |
source_location(klass.method(method_name)) |
OK, Let's begin. Hello, Everybody. | |
My name is Narihiro Nakamura. | |
Today, I'm talking about "Parallel worlds of CRuby's GC". | |
I'm very happy now, because I'm meeting attendee in rubyconf. | |
And, one of my dreams is to talk in rubyconf. | |
So, I'm very happy and exciting. | |
Today is my first presentation in English. | |
My English is not good. |
# -*- encoding: utf-8 -*- | |
Gem::Specification.new do |s| | |
s.name = 'parallel_assets_compiler' | |
s.version = '0.2.0' | |
s.platform = Gem::Platform::RUBY | |
s.author = 'Jørgen Orehøj Erichsen' | |
s.email = '[email protected]' | |
s.summary = 'Compile assets in parallel' | |
s.description = 'Compile assets in parallel to speed up deployment' |
# Outputs this at warn log level: | |
# 1.2.3.4 GET /path 200 OK BlahController#action HTML 938.2 (DB 11.8, View 719.7) {params} {optional params from flash[:log]} | |
# | |
# Save as config/initializers/oneline_detailed_logging.rb. Consider | |
# decreasing the log level from "info" to "warn" (in production.rb) so | |
# the one-line log message replaces the standard request logs. | |
# override process_action to add 2 things to the payload: | |
# - remote IP |
# Usage: rake name:task app_name | |
task PROD = "appname" # "task" here stubs to prevent rake errors with commandline | |
task STAGING = "appname-staging" | |
APP = ARGV[1] || PROD # default app | |
puts "=== APP #{APP} ===" | |
namespace :deploy do |
app_1: foreman start --root app_1 --port 3000 --env app_1/.env | |
app_2: foreman start --root app_2 --port 3100 --env app_2/.env | |
app_3: foreman start --root app_3 --port 3200 --env app_3/.env |
A not politically correct assertion of my feelings towards a piece of software:
Note: Repetition builds cynicism, asset_sync
isn't bad, but when an asset problem cannot be solved via support it gets escalated to me. Often times someone using asset_sync
the problem is due to their use of the library and not from Heroku.
The asset sync gem uploads your assets (images, css, javascript) to S3. From there you can either point browsers to the copy on S3 or use a CDN + the S3 bucket. It's a good idea, and solved a problem at one time.
It is no longer needed and you should now use https://devcenter.heroku.com/articles/using-amazon-cloudfront-cdn instead. So rather than copying your assets over to S3 after they are precompiled the CDN grabs them from your website instead. Here's some reasons why it's better.
#Yale LDAP Example | |
require 'csv' | |
require 'net-ldap' | |
# Hashrocket Format | |
{:host => 'directory.yale.edu', :port => 389} | |
# "New" Format, requires keys be symbols | |
{host: 'directory.yale.edu', port: 389} |