Skip to content

Instantly share code, notes, and snippets.

@hitode909
hitode909 / negaproxy.rb
Created April 18, 2010 08:36
画像の色を反転させるプロキシ
#!/usr/bin/env ruby
require 'webrick'
require 'webrick/httpproxy'
require 'RMagick'
handler = Proc.new() { |req,res|
if res['content-type'] =~ /image/
begin
img = Magick::Image.from_blob(res.body).first
@mhayashi1120
mhayashi1120 / fgit.el
Created October 21, 2010 13:01
my git interface
;;; fgit.el --- Functional Git interface for emacs
;; Copyright (C) 2010 by Hayashi Masahiro
;; Author: Hayashi Masahiro <mhayashi1120@gmail.com>
;; URL:
;; Keywords: Emacs, Git, Frontend
;; Version: 0.0.1
;; fgit.el is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
@bkudria
bkudria / flymake-fringe-icons.el
Created December 29, 2010 21:56
Add icons in the fringe, for flymake
(require 'fringe-helper)
(require 'flymake)
(defvar flymake-fringe-overlays nil)
(make-variable-buffer-local 'flymake-fringe-overlays)
(defadvice flymake-make-overlay (after add-to-fringe first
(beg end tooltip-text face mouse-face)
activate compile)
(push (fringe-helper-insert-region
;; http://d.hatena.ne.jp/kitokitoki/20101009/p6
(defmacro grep-no-more-read-only (name)
`(defadvice ,name (before ,(intern (concat "my-" (symbol-name name))) activate)
"Prevent Buffer is read-only: #<buffer *grep*> error"
(when (get-buffer "*grep*")
(when (y-or-n-p "Kill current *grep* buffer?")
(kill-buffer (get-buffer "*grep*"))))))
(grep-no-more-read-only lgrep)
#! /usr/bin/env ruby
# vim: set et sts=2 sw=2 ts=2 fdm=marker ft=ruby :
# author: takano32 <tak@no32 dot tk>
#
require 'rubygems'
require 'pit'
# ブラウザの起動とかを見えないようにできるけど、Xvfbとか必要
# Darwinじゃ使えないかもしれない。
@fand
fand / flux_history.md
Last active October 19, 2016 04:26
Flux戦争の歴史

Flux戦争の歴史メモ

Fluxxor by binarymuse

  • 2014/05/12 first commit
    • F8での "Flux" の登場からわずか4日
  • 素朴な実装
  • mixinベースの機能
    • 〜React v0.12という感じ

Reflux by spoike

@fukajun
fukajun / gist:edea3c4f36e37bf36e8b
Last active February 19, 2017 14:28
pecoでgit logから指定したコミットのハッシュを取るコマンド
git log --graph --pretty=format:'%d %an: %s %ar %h' | peco | awk -F ' ' '{ print $NF }'
@m2ym
m2ym / gist:774198
Created January 11, 2011 08:28
cl-indent-patchesの設定(Emacs LispとCommon Lispの共存)
(when (require 'cl-indent-patches nil t)
(setq lisp-indent-function
(lambda (&rest args)
(apply (if (memq major-mode '(emacs-lisp-mode lisp-interaction-mode))
'lisp-indent-function
'common-lisp-indent-function)
args))))
@youcune
youcune / fadein.html
Created August 24, 2014 12:23
CSS3 のみで display: none からフェードインさせる
<!DOCTYPE html>
<html>
<head>
<meta charst='utf-8'>
<title>TEST</title>
<script src="//code.jquery.com/jquery-1.11.1.min.js" type="text/javascript"></script>
<style>
.box {
background: #000000;
display: none;