nimgrep ユーザーズ・ガイド

作成者: アンドレアス・ルンプフ
バージョン: 0.9

Nimgrep は検索と置換処理ができるコマンドラインツールです。It can search for regex or peg patterns and can search whole directories at once. User confirmation for every single replace operation can be requested.

Nimgrep has particularly good support for Nim's eccentric style insensitivity. Apart from that it is a generic text manipulation tool.

インストール

このコマンドで nimgrep をコンパイルします。

nim c -d:release tools/nimgrep.nim

And copy the executable somewhere in your $PATH.

コマンドラインスイッチ

用法:
nimgrep [オプション] [パターン] [置換文字列] (ファイル/ディレクトリ)*
オプション:
--find, -f検索パターン (デフォルト)
--replace, -r置換パターン
--pegPEG パターンを使用します。
--re正規表現パターンを使用します (デフォルト)。正規表現の拡張構文は常時有効です。
--recursiveディレクトリを再帰的に処理します。
--confirmconfirm each occurrence/replacement; there is a chance to abort any time without touching the file
--stdinread pattern from stdin (to avoid the shell's confusing quoting rules)
--word, -wthe match should have word boundaries (buggy for pegs!)
--ignoreCase, -i英数大小文字を同一視します。
--ignoreStyle, -yスタイルを同一視します。
--ext:拡張子1|拡張子2|...指定された拡張子に該当するファイルのみ検索対象とします。
--verbosebe verbose: list every processed file
--help, -hこのヘルプを表示します。
--version, -vバージョンを表示します。