Skip to content

Instantly share code, notes, and snippets.

@kjunichi
kjunichi / puts_japanese_charactor.rb
Created May 20, 2015 05:48
文字コードを直接指定することで、WebRubyでも日本語をputsで表示出来た
a=0xE3.chr+0x81.chr+0x82.chr
puts a
@7shi
7shi / kbfc.cpp
Last active September 5, 2015 18:15
#include <stdio.h>
#include <string>
#include <vector>
#include <stack>
#include <windows.h> // PE関連の構造体のため
int addr_putchar = 0x00405044;
int addr_getchar = addr_putchar + 4;
int addr_buf = 0x00406000;
require 'tempfile'
def tempwrite
f = Tempfile.new('temp')
f.puts 'nihanihanihanihatorigairu'
f.close
return f
end
temp = tempwrite
@moro
moro / taptree.rb
Created September 28, 2010 02:09
class TapTree
module Adapter
def taptree(n = nil, filter = nil)
tap{|x| TapTree.new(x, filter).display(n) }
end
end
IGNORE = [TapTree::Adapter]
COLS = 100
def initialize(obj, filter_re = nil)
@mixin all-reset {
azimuth: center;
background: #fff;
border: none;
bottom: auto;
caption-side: top;
clear: none;
clip: auto;
color: #000;
content: '';
@ongaeshi
ongaeshi / gist:756364
Created December 27, 2010 18:03
Windowsでgroongaコンパイル時にエラー
i686-w64-mingw32-gcc は、cygwin付属のcygwin.dllに依存しないgcc4です。
% cd ~/work/rroonga/vendor/groonga-1.0.4
% ./configure CC='i686-w64-mingw32-gcc' CFLAGS='-g -O0 -mno-cygwin' prefix='/c/users/ongaeshi/work/rroonga/vendor/local' i386-pc-mingw32
% make
.
.
.
.
Making all in src
@ongaeshi
ongaeshi / .bashrc
Created January 12, 2011 08:55
my .bashrc setting.
# ----------------------------------------
# コマンドエイリアス
# ---------------------------------------
#PS1='<\w>'
#PS1='% '
PS1='$ '
# ----------------------------------------
# ヒストリ設定
# ---------------------------------------
@ongaeshi
ongaeshi / font-settting.el
Created January 18, 2011 01:13
フォント設定
;;; font-setting.el
;;
;; 参考にしたページ
;;
;; フォントの設定 - Meadow - Trac
;; http://www.meadowy.org/meadow/wiki/%E3%83%95%E3%82%A9%E3%83%B3%E3%83%88%E3%81%AE%E8%A8%AD%E5%AE%9A
;;
;; 試し方
;; [Options] -> Set Font/Font Setで設定されているフォントを試すことが出来ます
;;
;;; color-setting.el
;;
;; (require 'color-setting)
; フェイスカスタマイズのために先行して読み込む必要があるもの
(require 'dired)
(require 'compile)
;;; font-lock-modeを有効に
(global-font-lock-mode t)
@ongaeshi
ongaeshi / anything-setting.el
Created February 18, 2011 02:03
my anything setting
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;anything
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(require 'anything-startup)
; anything-for-filesの内容をカスタマイズ、anything-c-source-locateを除外
(setq anything-for-files-prefered-list
'(anything-c-source-ffap-line
anything-c-source-ffap-guesser
anything-c-source-buffers+