オフラインリアルタイムどう書く という、 @Nabetani さん主催のイベントを模したものを ESM の社内向けに行ったものです。
出題者: @mtsmfm スペシャルサンクス: @mattsan
{"name"=>"set_debug", "args"=>[true]} | |
{"response"=>true} | |
{"name"=>"visit", "args"=>["http://127.0.0.1:37796/users/new"]} | |
poltergeist [1398005093288] state default -> loading | |
[deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message. | |
poltergeist [1398005093702] state loading -> default | |
{"response"=>{"status"=>"success"}} | |
{"name"=>"find", "args"=>[:css, "body"]} | |
{"response"=>{"page_id"=>1, "ids"=>[0]}} | |
{"name"=>"visible", "args"=>[1, 0]} |
source 'https://rubygems.org' | |
gem 'capybara' | |
gem 'poltergeist', require: 'capybara/poltergeist' |
{ | |
"app/assets/javascripts/components/*.js.cjsx": { | |
"command": "jcomponent", | |
"template": "@{camelcase|capitalize|colons} = React.createClass\n render: ->" | |
}, | |
"app/assets/javascripts/actions/*.js.coffee": { | |
"command": "jaction", | |
"template": "class @{camelcase|capitalize|colons}" | |
}, | |
"app/assets/javascripts/constants/*.js.coffee": { |
require 'active_support' | |
require 'active_support/core_ext/object/to_query' | |
require 'active_support/core_ext/string/strip' | |
params = { | |
title: '問題を一言で', | |
labels: %w(bug), | |
body: <<-EOS.strip_heredoc | |
## 出す前に確認しよう |
CSON = require 'season' | |
ObjectAssign = require 'object-assign' | |
linuxCson = CSON.readFileSync('linux.cson') | |
darwinCson = CSON.readFileSync('darwin.cson') | |
obj = {} | |
for k1, v1 of linuxCson | |
obj[k1] = {} |
source 'https://rubygems.org' | |
gem 'activesupport', require: 'active_support/all' | |
gem 'pry-byebug' |
オフラインリアルタイムどう書く という、 @Nabetani さん主催のイベントを模したものを ESM の社内向けに行ったものです。
出題者: @mtsmfm スペシャルサンクス: @mattsan
#coding:utf-8 | |
def fuga(n, i, n_max) | |
kugiru = 2 ** (i+1) | |
tonari = 2 ** i | |
if(n % kugiru < kugiru/2) | |
n + tonari | |
else | |
n - tonari |
source "https://rubygems.org" | |
gem 'pry' | |
gem 'activesupport', require: 'active_support/all' |
run 'echo "" > Gemfile' | |
add_source 'https://rubygems.org' | |
gem 'rails', '3.2.13' | |
gem_group :development, :test do | |
gem 'sqlite3', '1.3.5' | |
gem 'rspec-rails', '2.11.0' | |
end |