$ sudo xcodebuild -license
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
$ curl -s "https://get.sdkman.io" | bash
| tap "homebrew/bundle" | |
| tap "homebrew/cask" | |
| tap "homebrew/core" | |
| tap "thoughtbot/formulae" | |
| brew "carthage" | |
| brew "ffmpeg" | |
| brew "gist" | |
| brew "mas" | |
| brew "pidcat" |
| import android.util.Log; | |
| import java.util.HashMap; | |
| import java.util.Map; | |
| import rx.Observable; | |
| import rx.Observable.OnSubscribe; | |
| import rx.Subscriber; | |
| import rx.functions.Action1; |
| case class MyClass(number: Int, multiplier: Multiplier) { | |
| def calc: Int = { | |
| number * multiplier.number | |
| } | |
| } | |
| case class Multiplier(number: Int) | |
| class Core { | |
| def run(): Boolean = { | |
| true | |
| } | |
| } |
ユニットテストを書こう!http://qiita.com/kompiro/items/78f2c8d2022a685baa83
プロダクションコードの変更時、既存と振る舞いが変わる箇所はテストが失敗する。そのため、変更が影響を及ぼす範囲がわかる
ユニットテストを書くと、コードの振る舞いがテストコードに明示されるため、振る舞いを予測可能な範囲が増える
ユニットテストを書くときは、APIの利用者になるため、APIの利用者から見て利用しやすいコードを目指すモチベーションを産みやすい
| (ns fp.match | |
| (:require [clojure.core.match :refer (match)])) | |
| (defprotocol TFizzBuzz | |
| (to-string [this])) | |
| (deftype Fizz [number] TFizzBuzz | |
| (to-string [this] "Fizz")) | |
| (deftype Buzz [number] TFizzBuzz | |
| (to-string [this] "Buzz")) |
Install webpack
npm install webpack -g
Build
webpack ./main.js bundle.js
htmlファイルを作成
touch index.html
vi index.html
<h1>Hello World</h1>| // Use Gists to store code you would like to remember later on | |
| console.log(window); // log the "window" object to the console |