Skip to content

Instantly share code, notes, and snippets.

View soichisumi's full-sized avatar
🔥
gRPC, Kubernetes, GCP, AWS, Azure, Firebase / Go, Javascript, Rust <- new!

Soichi Sumi soichisumi

🔥
gRPC, Kubernetes, GCP, AWS, Azure, Firebase / Go, Javascript, Rust <- new!
View GitHub Profile
@soichisumi
soichisumi / maxlen.py
Last active September 30, 2017 18:27
都道府県+市区町村の名前の最大長を調べた
import pandas as pd
import math as ma
import sys
import googlemaps
df = pd.read_csv('jusho.csv')
maxlen=0
maxlenKen=0
maxlenSi=0
for key, row in df.iterrows():
if maxlenKen<len(row[1]):
@soichisumi
soichisumi / Hoge.java
Last active October 7, 2017 22:37
mockito and powermockito test example
/**
* Created by souichi_sumi on 2017/09/28.
*/
//unimplemented class
public class Hoge {
static String var1 = "hoge1";
static String var2 = "hoge2";
static String var3 = "hoge3";
static String var4 = "hoge4";
@soichisumi
soichisumi / openIterm2.js
Created November 5, 2017 12:19
Script to open iTerm2 and
function run(input, parameters) {
// open iterm2 and retrieve session object
var iTerm = Application("iTerm2");
var win = iTerm.createWindowWithDefaultProfile();
var tab = win.currentTab();
var ses = tab.currentSession();
//run command in the session
ses.write({text: "echo yoyo"});
@soichisumi
soichisumi / openIterm2.apScript
Last active November 5, 2017 13:23
apple script to run multiple commnands
on run {input, parameters}
tell application "iTerm"
activate
create window with default profile
set mySession to (current session of current tab of current window)
tell mySession
write text "echo yoyo"
repeat while is processing of mySession is true
delay 1
@soichisumi
soichisumi / FastFile
Created May 21, 2018 09:53
FastFileの実験跡
default_platform(:ios)
platform :ios do
desc "test"
lane :testlane do
sh("ls")
end
@soichisumi
soichisumi / zsh-colors.sh
Created July 23, 2018 08:49
zsh-colors.sh
for c in {000..255}; do echo -n "\e[38;5;${c}m $c" ; [ $(($c%16)) -eq 15 ] && echo;done;echo
let humans = new Array()
humans.push({
name: "yoyo",
age: 26
})
humans.push({
name: "test",
age: 55
})
humans.push({
console.log('<yo#ooooo>'.replace(/#/g, 'eh'))
console.log('<yo#ooooo>'.replace(/#/g, 'eh'))