LoginSignup
13
13

More than 5 years have passed since last update.

Vim から migemogrep を使う方法

Last updated at Posted at 2014-07-22

migemogrep とは

migemogrep は kaoriya 氏によって開発されている gomigemo を使用し、peco から migemo 検索をする為だけに作られた外部コマンドです。動機は peco ですが、通常の grep として使えたら便利だろうなと思いましたので、grep としても使える程度の実装を目指しています。現在バージョンは 0.1.0 ですが、0.1.1 がリリースされた際にはとても有用な外部コマンドとなる予定です。

インストール

0.1.1 がリリースされた際にはバイナリパッケージも用意される予定です。以下待ちきれない人向けのビルド手順です。

$ go get github.com/peco/migemogrep

Vim から使おう

migemogrep のリポジトリに misc/vim というフォルダが含まれていますので、それをローカルにコピーして頂くか、rtp に追加します。以下はvimrcで動的にrtpを追加する場合のコードです。

exe "set rtp+=" . globpath(substitute($GOPATH, (has('win32')||has('win64'))?';':':',',','g'), 'src/github.com/peco/migemogrep/misc/vim')

あとは

:MigemoGrep sonomasakada **/*

といった具合にお使い下さい。

13
13
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
13
13