migemo
の Formula を作りました。本来であれば、pull request 送るもの
だと思いますが、日本語に特化したツールのリクエストを送って良いか判
断が付かなかったので、とりあえず gist に上げました。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Migemo < Formula | |
url 'http://0xcc.net/migemo/migemo-0.40.tar.gz' | |
homepage 'http://0xcc.net/migemo/' | |
md5 '7021c45096b6816fccf16f8389324a91' | |
depends_on 'emacs' | |
depends_on 'ruby-bsearch' | |
depends_on 'ruby-romkan' | |
def install | |
ENV['RUBYLIB'] = "#{HOMEBREW_PREFIX}/lib/ruby"; | |
system "./configure", "--disable-debug", "--disable-dependency-tracking", | |
"--prefix=#{prefix}", "--with-rubydir=#{prefix}/lib/ruby" | |
system "make" | |
system "make install" | |
end | |
def caveats; <<-EOS.undent | |
To export the needed variable, add this to your dotfiles. | |
* On Bash, add this to `~/.bash_profile`. | |
* On Zsh, add this to `~/.zprofile` instead. | |
export RUBYLIB=#{HOMEBREW_PREFIX}/lib/ruby | |
To export the needed expression, add this to your `~/.emacs`. | |
(require 'migemo) | |
EOS | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class RubyBsearch < Formula | |
url 'http://0xcc.net/ruby-bsearch/ruby-bsearch-1.5.tar.gz' | |
homepage 'http://0xcc.net/ruby-bsearch/' | |
md5 'fb3cb15bb3546fb3b5d4ba5a61baeea1' | |
def install | |
system "mkdir -p #{prefix}/lib/ruby" | |
system "install -c -m 644 bsearch.rb #{prefix}/lib/ruby" | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class RubyRomkan < Formula | |
url 'http://0xcc.net/ruby-romkan/ruby-romkan-0.4.tar.gz' | |
homepage 'http://0xcc.net/ruby-romkan/' | |
md5 'bc48a51bd6cf0e4ff1d73faffef531fb' | |
def install | |
system "mkdir -p #{prefix}/lib/ruby" | |
system "install -c -m 644 romkan.rb #{prefix}/lib/ruby" | |
end | |
end |
/usr/local/Library/Formula 以下に上記 Formula をコピーしたら、
“brew install migemo” するだけでインストールできます。
あとは以下を設定するだけです。
# ~/.zshenv
export RUBYLIB=/usr/local/lib/ruby
;; ~/.emacs
(require 'migemo)
追記(2011-11-26):
pull request を送りました。
気長に待ちます。
追記(2011-11-28):
却下されました。migemo の Formula が depends_on ’emacs’ なことと、
ruby-(bsearch|romkan) が gems に存在するためとのこと。