Skip to content

Instantly share code, notes, and snippets.

View takuhiro's full-sized avatar

Takuhiro Yoshida takuhiro

View GitHub Profile
@takuhiro
takuhiro / sdnotify-proxy
Last active February 13, 2020 08:15
test
This file has been truncated, but you can view the full file.
@takuhiro
takuhiro / httpserver.go
Last active June 21, 2020 23:23
Prometheus Instrumentation Sample
package main
import (
"fmt"
"log"
"math/rand"
"net/http"
"time"
"github.com/prometheus/client_golang/prometheus"
@takuhiro
takuhiro / file0.txt
Created June 15, 2017 01:49
Androidでの正しいログ出力方法(標準Logクラス vs AnkoLogger) ref: http://qiita.com/takuhiro/items/bfbecffbb1ca6e6603a3
if ( Log.isLoggable(TAG, DEBUG) ) Log.d(TAG, "foo");
@takuhiro
takuhiro / file0.txt
Last active June 13, 2017 02:21
5分でできる Kotlin + CLI で "Hello, World!" ref: http://qiita.com/takuhiro/items/994a99611c97550a5d68
$ brew update
$ brew install kotlin
@takuhiro
takuhiro / AndroidManifesto.xml
Created May 11, 2017 01:43
Androidで画像を選択して、S3にアップロードする ref: http://qiita.com/takuhiro/items/a04974f0f09e5f68805a
<service
android:name="com.amazonaws.mobileconnectors.s3.transferutility.TransferService"
android:enabled="true" />
@takuhiro
takuhiro / file0.txt
Last active March 3, 2017 03:51
Chrome拡張でAWSコンソールでのオペミスを防止する ref: http://qiita.com/takuhiro/items/e21188a6f2de5f88471f
東京(ap-northeast-1) => プロダクション環境
バージニア(us-east-1) => 開発(ステージング)環境
@takuhiro
takuhiro / file0.txt
Created November 16, 2016 02:33
Hardware acceleration によって Canvas が動かない場合の対処法 ref: http://qiita.com/takuhiro/items/3310001ce5809048eca5
@Override
protected void onDraw(Canvas canvas) {
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.JELLY_BEAN_MR2) {
// Turn off hardware acceleration to use Canvas#clipPath()
// See https://developer.android.com/guide/topics/graphics/hardware-accel.html#unsupported
setLayerType(View.LAYER_TYPE_SOFTWARE, null);
}
canvas.clipPath(mPath);
super.onDraw(canvas);
}