Skip to content

Instantly share code, notes, and snippets.

@uskanda
uskanda / anything-c-source-mac-spotlight2.el
Created Nov 19, 2011
[Emacs]anything source of spotlight (open binary files by associated mac application)
View anything-c-source-mac-spotlight2.el
(defcustom anything-c-source-mac-spotlight2-open-file-extensions
'("pdf" "jpg" "gif" "psd" "ai" "png" "mpg" "avi" "mov")
"List of file extensions to open by Mac OS X application."
:type 'list
:group 'anything-c-source-mac-spotlight2)
(defvar anything-c-source-mac-spotlight2
'((name . "mdfind")
(candidates
. (lambda () (start-process "mdfind-process" nil "mdfind" anything-pattern)))
@uskanda
uskanda / rvm-auto-switch.el
Created Nov 23, 2011
[Emacs]Auto RVM switcher (when start up inf-ruby, rails console, webserver)
View rvm-auto-switch.el
;; dependency: rvm rinari
(defadvice rinari-web-server (before rvm-switch-rinari-web-server)
(rvm-activate-corresponding-ruby))
(ad-activate 'rinari-web-server)
(defadvice rinari-console (before rvm-switch-rinari-console)
(rvm-activate-corresponding-ruby))
(ad-activate 'rinari-console)
(defadvice run-ruby (before rvm-switch-run-ruby)
@uskanda
uskanda / col-highlight-disable-when-execute-dropdown.el
Created Dec 2, 2011
[Emacs]Advice for yasnippet(dropdown-list) to fix display corruption when using col-highlight.el(vline.el)
View col-highlight-disable-when-execute-dropdown.el
(defadvice dropdown-list (around col-highlight-disable-when-execute-dropdown)
(progn (toggle-highlight-column-when-idle 0)
ad-do-it
(toggle-highlight-column-when-idle 1)))
(ad-activate 'dropdown-list)
@uskanda
uskanda / show.html.erb.patch
Created Jul 13, 2012
Gantt with date display patch for Redmine 2.0.3.stable.9920
View show.html.erb.patch
--- show.html.erb.org 2012-07-14 06:22:37.254627009 +0900
+++ show.html.erb 2012-07-14 06:33:37.010631122 +0900
@@ -41,6 +41,7 @@
headers_height = header_heigth
show_weeks = false
show_days = false
+show_day_num = false
if @gantt.zoom > 1
show_weeks = true
View Rakefile
# -*- coding: utf-8 -*-
# Rictyフォントを入れるための手順をまとめた、自分用のRakefileです。
# Ricty http://save.sys.t.u-tokyo.ac.jp/~yusa/fonts/ricty.html
#
# Rakefileのフォーマット http://www.kyobashi.org/hf/RakeUserGuide/?RakefileFormat
#
# 2012/11/05 taktamur@gmail.com
# clean/clobberについては http://www2s.biglobe.ne.jp/~idesaku/sss/tech/rake/
require 'rake/clean'
@uskanda
uskanda / install_env.sh
Last active Dec 29, 2015
Develop environment set up script
View install_env.sh
#!/bin/sh
gem install homesick
sudo gem install brewdler
homesick clone git@github.com:uskanda/unix-rc.git
homesick symlink unix-rc
homesick clone git@github.com:uskanda/vimrc.git
homesick symlink vimrc
brew update
brew install rbenv ruby-build
@uskanda
uskanda / emacs.rb
Created Aug 3, 2011 — forked from pingles/emacs.rb
Homebrew Emacs 23.3a for OSX Lion with native full-screen, inline patch
View emacs.rb
require 'formula'
class Emacs < Formula
url 'http://ftp.gnu.org/pub/gnu/emacs/emacs-23.3a.tar.bz2'
md5 'f2cf8dc6f28f8ae59bc695b4ddda339c'
homepage 'http://www.gnu.org/software/emacs/'
if ARGV.include? "--use-git-head"
head 'git://repo.or.cz/emacs.git'
else