Skip to content

Instantly share code, notes, and snippets.

View riaf's full-sized avatar
🏠
Working from home

Keisuke SATO riaf

🏠
Working from home
View GitHub Profile
@voluntas
voluntas / webrtc.rst
Last active April 30, 2024 14:20
WebRTC コトハジメ
@remy
remy / gist:350433
Created March 31, 2010 14:58
Storage polyfill
if (typeof window.localStorage == 'undefined' || typeof window.sessionStorage == 'undefined') (function () {
var Storage = function (type) {
function createCookie(name, value, days) {
var date, expires;
if (days) {
date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
expires = "; expires="+date.toGMTString();
@io41
io41 / paginated_collection.js
Created February 22, 2011 10:10 — forked from zerowidth/paginated_collection.js
Pagination with Backbone.js
// includes bindings for fetching/fetched
var PaginatedCollection = Backbone.Collection.extend({
initialize: function() {
_.bindAll(this, 'parse', 'url', 'pageInfo', 'nextPage', 'previousPage');
typeof(options) != 'undefined' || (options = {});
this.page = 1;
typeof(this.perPage) != 'undefined' || (this.perPage = 10);
},
fetch: function(options) {
@tcnksm
tcnksm / docker_cheat.md
Last active August 5, 2021 03:59 — forked from wsargent/docker_cheat.md
Docker 虎の巻

Docker 虎の巻

何故Dockerを使うべきか

Why Should I Care (For Developers)

"Dockerが面白いのはシンプルな環境に隔離性と再現性をもたらしてくれることだ.ランタイムの環境を一度作れば、パッケージにして別のマシンでも再利用することできる.さらに,すべてはホスト内の隔離された環境で行われる(VMのように).最も素晴らしい点は,シンプルかつ高速であることだ."

[
"about",
"ac",
"access",
"account",
"accounts",
"activate",
"ad",
"add",
"address",
saykanji()
{
voice=`kanji2voice "$1"`
echokanji "$voice"
/usr/local/bin/saykana "$voice" &
}
#FORMAT_OPTION='--node-format=%pS%f[8] --unk-format=%M --eos-format="\n"'
sayeb()
{
<?php
/**
* Geohash
*
* @author Keisuke SATO
* @license MIT License
*
* # Based
* http://github.com/davetroy/geohash-js/blob/master/geohash.js
* Geohash library for Javascript
@riaf
riaf / riaf.min.svg
Last active November 21, 2017 07:12
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@brtriver
brtriver / update2.2to2.3.md
Last active December 18, 2015 01:29
Symfony2.3にあげるときにはまったこと

Symfony を 2.2 から 2.3 にアップしたときのメモ

  • updateするときのお話。新規でcreate-projectするなら何も困らない

  • php composer.phar update する前に以下をチェック

  • composer.jsonの修正

  • http://symfony.com/blog/symfony-2-3-0-the-first-lts-is-now-available

  • キャッシュファイルは事前にrmしておく

  • icuが4.4以上でないと怒られるので、事前にインストールしているicuのバージョンをチェックしておくこと

  • composer.jsonでバージョン指定すれば回避可能 http://php-sql-gdgd.jugem.jp/?eid=104