Skip to content

Instantly share code, notes, and snippets.

View ogawaso's full-sized avatar

Soichiro Ogawa ogawaso

  • Circlace inc
  • JP/Kanagawa
View GitHub Profile

多摩動物公園

履歴

  • 2024/04/20 5歳8ヶ月

見どころ

ライオンバス

  • 動物公園に入場してからさらにライオンバスの場所でチケットを買う必要がある。
  • 結構人気なので、朝一に行くのが良い。
<!DOCTYPE HTML>
<html>
<head>
<meta charset="UTF-8">
<title>タイトル</title>
</head>
<body>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js" >
</script>
<script src="http://documentcloud.github.com/underscore/underscore-min.js"></script>
#chef-solos to work on ruby-2.0.0-p195
touch ~/.rbenv/versions/2.0.0-p195/lib/ruby/2.0.0/rubygems/format.rb
@ogawaso
ogawaso / .rubocop.yml
Created May 8, 2013 10:58
my rubocop gist
# This is the default configuration file with all checking enabled. It is also
# the configuration used to check the rubocop source code.
# Use UTF-8 as the source file encoding.
Encoding:
Enabled: true
# Limit lines to 80 characters.
LineLength:
Enabled: true
# -*- coding: utf-8 -*-
puts "gist.vim test"
@ogawaso
ogawaso / gist:2724445
Created May 18, 2012 10:13
delete_all of all models
Dir.glob("app/models/*.rb").
map{|m|m.gsub("app/models/", "")}.
map{|m| m.gsub(".rb", "")}.each do |m|
clazz = m.classify.constantize
next unless clazz.kind_of?(ActiveRecord::Base)
clazz.delete_all
end
@ogawaso
ogawaso / gist:2652755
Created May 10, 2012 12:27
controllerのspecサンプル
[:action1, :action2].each do |a|
it "should be successfl" do
get a
response.should be_success
end
end
@ogawaso
ogawaso / hoge.rb
Created March 27, 2012 02:12
difference between for and each in ruby
# -*- coding: utf-8 -*-
a= [1, 2, 3]
for v in a
b = 'a'
puts v
end
puts b
a.each do |v|
c = 'a'