Skip to content

Instantly share code, notes, and snippets.

View rhiokim's full-sized avatar
:octocat:
I'm focusing on somewhere.

Rhio Kim rhiokim

:octocat:
I'm focusing on somewhere.
View GitHub Profile
/*
* Based on https://gist.github.com/583836 from http://stackoverflow.com/questions/3709391/node-js-base64-encode-a-downloaded-image-for-use-in-data-uri.
* Neither that gist nor this one work for me in 0.2.x or 0.3.x.
*/
var request = require('request'),
BufferList = require('bufferlist').BufferList,
sys = require('sys'),
bl = new BufferList(),
url = 'http://nodejs.org/logo.png'
;
@rhiokim
rhiokim / busybox-link.sh
Created September 2, 2011 16:41
Linux myxtreamer 2.6.12.6-VENUS BusyBox symbol link Creator
@rhiokim
rhiokim / xmp_base.sh
Created September 6, 2011 15:28
install XMP's base module on xtreamer
#!/bin/sh
base=`pwd`
programs=`dirname $base`
xmp=`dirname $programs`
xmproot=`dirname $xmp`
rm /sbin/www/xmproot
rm /sbin/www/xmp
@rhiokim
rhiokim / xmp_base.sh
Created September 6, 2011 16:28
install XMP's base module on xtreamer
#!/bin/sh
base=`pwd`
programs=`dirname $base`
xmp=`dirname $programs`
xmproot=`dirname $xmp`
rm /sbin/www/xmproot
rm /sbin/www/xmp
@rhiokim
rhiokim / LICENSE.txt
Created November 12, 2011 05:45 — forked from jed/LICENSE.txt
generate random UUIDs
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Jed Schmidt <http://jed.is>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@rhiokim
rhiokim / LICENSE.txt
Created November 12, 2011 05:47 — forked from aemkei/LICENSE.txt
hsl2rgb - 140byt.es
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@rhiokim
rhiokim / LICENSE.txt
Created November 12, 2011 05:46 — forked from p01/LICENSE.txt
Sudoku Solver in 140bytes
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Mathieu 'p01' Henri - http://www.p01.org/releases/
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@rhiokim
rhiokim / LICENSE.txt
Created November 12, 2011 05:47 — forked from aemkei/LICENSE.txt
140byt.es - Base64 encoder
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@rhiokim
rhiokim / scaling_isomorphic_javascript_code.ja.markdown
Created November 15, 2011 04:10 — forked from tily/scaling_isomorphic_javascript_code.ja.markdown
サバクラ両方で動く JavaScript の大規模開発を行うために

サバクラ両方で動く JavaScript の大規模開発を行うために

原文:Scaling Isomorphic Javascript Code (This is just for study, please contact me at tily05 atmark gmail.com if any problem.)

考えてみれば Model-View-Controller とか MVC ってよく聞くよね。実際どんなものか知ってる? 抽象的に言うなら「オブジェクト情報の保持されるグラフィック・システム (つまり、ラスターではないグラフィック。ゲームとか) 上に構築された、表示系を中心としたアプリケーションにおいて、主要な機能どうしの関わりをうまく分離すること」とでも言おうか。もう少し深く考えを押し進めてみれば、これは当然、他のさまざまなアプリケーションにもあてはまる言葉 (bucket term ?) だ。

過去に多くの開発コミュニティが MVC による解決案を提供し、それによってよくあるユースケースにうまく対処し、地位を築くことができた。例をあげるなら、Ruby や Python コミュニティは Rails や Django を作り、MVC アーキテクチャを実現した。

@rhiokim
rhiokim / client.js
Created December 11, 2011 02:11 — forked from hagino3000/client.js
WebSocket with binary data
var socket = null;
function bootstrap() {
// 適当な図形を描画
var c = document.getElementById('mycanvas');
var ctx = c.getContext('2d');
ctx.globalalpha = 0.3;
for(var i=0; i<1000; i++) {
ctx.beginPath();