This file contains 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
$ wget http://nginx.org/keys/nginx_signing.key | |
$ sudo apt-key add nginx_signing.key | |
$ sudo vim /etc/apt/sources.list | |
+ deb http://nginx.org/packages/ubuntu/ oneiric nginx | |
+ deb-src http://nginx.org/packages/ubuntu/ oneiric nginx | |
$ apt-get update | |
# Get:1 http://nginx.org oneiric Release.gpg [287 B] とかちゃんと取ってきてるのを確認 | |
$ apt-get install nginx | |
# Setting up nginx (1.2.4-1~oneiric) ... |
This file contains 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
> system('ruby -e "puts 1+1"', intern=TRUE) | |
[1] "2" | |
> system("ruby script.rb", intern=T) |
This file contains 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
# see http://stackoverflow.com/questions/5880962/how-to-destroy-jobs-enqueued-by-resque-workers - old version | |
# see https://github.com/defunkt/resque/issues/49 | |
# see http://redis.io/commands - new commands | |
namespace :resque do | |
desc "Clear pending tasks" | |
task :clear => :environment do | |
queues = Resque.queues | |
queues.each do |queue_name| | |
puts "Clearing #{queue_name}..." |
This file contains 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
if (WebViewBridge) { | |
document.addEventListener('selectionchange', function(){ | |
var body = document.getSelection().toString(); | |
var object = { "type": "select", body: body } | |
WebViewBridge.send(JSON.stringify(object)); | |
}); | |
} |
This file contains 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
Verifying my Blockstack ID is secured with the address 1KcLD7r8UgtuMkqvUHQsjEjgHF1CjJxvkX https://explorer.blockstack.org/address/1KcLD7r8UgtuMkqvUHQsjEjgHF1CjJxvkX |
This file contains 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
Verifying that "foloinfo.id" is my Blockstack ID. https://explorer.blockstack.org/name/foloinfo.id |
This file contains 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
// Amazon購入履歴のCSVエクスポート | |
// | |
// 使い方: | |
// 1. 全部コピーする (右上の Raw をクリックした先でやるのが楽) | |
// 2. Amazon の注文履歴ページ ( https://www.amazon.co.jp/gp/css/order-history/ ) を開く | |
// 3. F12 または 右クリ→要素の検証 とかで出てくる開発者ツールのコンソール (JavaScript REPL) にペースト | |
// 4. エンターで実行 | |
// (Firefox はなんか allow pasting とタイプしろみたいなことを言われるので従う) | |
// 5. しばらく待つと、コンソールに合計金額が表示され、CSVが保存される | |
// |
This file contains 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
// img | |
// { | |
// uri: '"assets-library://asset/asset.JPG?id=SOME_ID&ext=JPG"', | |
// md5: "some md5" | |
// } | |
// copy into cache dir first | |
const path = FileSystem.cacheDirectory + img.md5 | |
await FileSystem.copyAsync({ | |
from: img.uri, |
This file contains 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
@font-face{ | |
font-family: 'Fira Code'; | |
src: url('https://raw.githubusercontent.com/tonsky/FiraCode/master/distr/eot/FiraCode-Regular.eot') format('embedded-opentype'), | |
url('https://raw.githubusercontent.com/tonsky/FiraCode/master/distr/woff2/FiraCode-Regular.woff2') format('woff2'), | |
url('https://raw.githubusercontent.com/tonsky/FiraCode/master/distr/woff/FiraCode-Regular.woff') format('woff'), | |
url('https://raw.githubusercontent.com/tonsky/FiraCode/master/distr/ttf/FiraCode-Regular.ttf') format('truetype'); | |
font-weight: normal; | |
font-style: normal; | |
} |
OlderNewer