FROM vixns/java8
RUN cp -p /usr/share/zoneinfo/Asia/Tokyo /etc/localtime
RUN apt-get -y update && apt-get -y install wget unzip mysql-client ftp ruby ruby-msgpack ruby-yajl libmysqld-dev libmysqlclient-dev ruby-dev gcc build-essential
RUN gem install rake td mysql2
ARG TD_API_KEY=${TD_APIKEY}
RUN echo 'Y' | td wf
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"account_already_exists": "アカウントがすでに存在します", | |
"account_country_invalid_address": "アカウントの国籍とビジネスを行う国籍が異なります", | |
"account_invalid": "アカウントが不正です", | |
"account_number_invalid": "口座番号が不正です", | |
"alipay_upgrade_required": "Alipayのアップデートが必要です", | |
"amount_too_large": "金額が多すぎます", | |
"amount_too_small": "金額が少なすぎます", | |
"api_key_expired": "APIキーが失効しています", | |
"balance_insufficient": "残高不足です", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RSpec::Matchers.define :eq_as_utf8_mac do |expected| | |
match do |actual| | |
actual.force_encoding('UTF8-MAC') === expected.encode('UTF8-MAC') | |
end | |
end | |
expected = 'ぱぴぷぺぽ' | |
# actual = 'ぱぴぷぺぽ' gots from iOS App through appium server. | |
expect(find(actual).name.strip) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
require 'rufus-scheduler' | |
$stdout.sync = true | |
scheduler = Rufus::Scheduler.new | |
def exec_command(cmd) | |
IO.popen(cmd) do |io| | |
while (line = io.gets) do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'selenium-webdriver' | |
require 'logger' | |
class AppiumServer | |
def initialize(opts = {}) | |
@port = Selenium::WebDriver::PortProber.above(3000) | |
@log = ::Logger.new(STDOUT) | |
end | |
def start |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
import "fmt" | |
func main() { | |
var a chan struct{} | |
fmt.Println("Hello, playground") | |
a = make(chan struct{}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def wait? &block | |
i = 1 | |
while i < 5 do | |
block.call(i) | |
sleep 0.2 | |
i = i+1 | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum SoundEffectType:Int { | |
case Whitsle = 0, | |
Finish, | |
CDThree, | |
CDTwo, | |
CDOne, | |
CDGo, | |
Good, | |
Great, | |
Excellent, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// reference: https://github.com/pepelkod/iOS-Examples/blob/master/PlaySoundWithVolume/PlaySoundWithVolumeAction.m | |
import SpriteKit | |
public extension SKAction { | |
public class func playSoundFileNamed(fileName: String, atVolume: Float, waitForCompletion: Bool) -> SKAction { | |
let nameOnly = fileName.stringByDeletingPathExtension | |
let fileExt = fileName.pathExtension | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
slick { | |
default="infra.dao.*" | |
dbs { | |
default { | |
driver="slick.driver.MySQLDriver$" | |
db { | |
driver=com.mysql.jdbc.Driver | |
url="jdbc:mysql://127.0.0.1:3306/dev?useUnicode=true&characterEncoding=UTF-8" |
NewerOlder