ターミナル実行
ssh-keygen と打ち込む
Generating public/private rsa key pair. Enter file in which to save the key (/Users/chsh/.ssh/id_rsa):
とでてくるのでリターン。
| upstream hogehoge_backend { | |
| server unix:/tmp/unicorn-hogehoge.sock; | |
| } | |
| server { | |
| listen 80; | |
| server_name hogehoge.com; | |
| location / { | |
| server_name_in_redirect off; | 
| class Foo < ActiveRecord::Base | |
| belongs_to :target, polymorphic: true | |
| # This validation will fail... | |
| # validates :target, uniqueness: true | |
| validates :target_type, | |
| presence: {if: :target_id_present? } | |
| validates :target_id, | |
| presence: {if: :target_type_present? }, | 
| source 'https://rubygems.org' | |
| gem 'rails', '3.2.8' | |
| # Bundle edge Rails instead: | |
| # gem 'rails', :git => 'git://github.com/rails/rails.git' | |
| gem 'pg' | |
| module CopyrightYears | |
| def copyright_years(now = nil) | |
| now ||= Time.now | |
| years = (2012 .. now.year).to_a | |
| case years.length | |
| when 1 then years[0] | |
| when 2 then years.join(', ') | |
| else | |
| "#{years.first}-#{years.last}" | |
| end | 
ターミナル実行
ssh-keygen と打ち込む
Generating public/private rsa key pair. Enter file in which to save the key (/Users/chsh/.ssh/id_rsa):
とでてくるのでリターン。
| {% google_form 123... Thanks for your message! %> | 
| #!/bin/bash | |
| export APPT=$1 | |
| source /etc/unicorn/$APPT.conf | |
| echo App Target: $APPT | |
| export RUBY_VERSION=ruby-$RUBY_VER | |
| export GEM_HOME=/bundles/$RUBY_VER/ruby/1.9.1 | 
| source "https://rubygems.org" | |
| gem 'podio' | |
| gem 'nokogiri' | 
| # A Liquid tag for Jekyll sites that allows embedding URL. | |
| # | |
| # Usage: {% crawlquote http://www.google.co.jp/ %} | |
| require 'cgi' | |
| require 'digest/md5' | |
| require 'net/https' | |
| require 'uri' | |
| require 'open-uri' | |
| require 'nokogiri' | 
| # usage: prex('ab_cd') generates %w(ab_cd ab_c abc a_cd a_c ac). | |
| # It's useful for prefix match without regular expression. :-) | |
| def xpand(array) | |
| first, *others = array | |
| return first if others == [] | |
| first.map do |it| | |
| xpand(others).map do |jt| | |
| [it + '_' + jt, it + jt] | |
| end.flatten |