さとうふみやす @ OSSTech です。

At Tue, 04 Nov 2014 17:13:00 +0900,
TANAKA Hidemune wrote:
> 以下のようなスクリプトを使って、
> allfind.sh
> ------------------------------------------
> #!/bin/bash
> 
> find ./ -name "*" -exec grep 2>/dev/null -H "$1" {} \;
> ------------------------------------------

  find ./ -name "*" -exec grep 2>/dev/null -H "$1" {} +

とすると、もっと効率的で速いですよ。

  find ./ -type f -exec grep -H "$1" {} +

でいいような気も。

  find ./ -type f -exec grep -H -- "$1" {} +

とすればハイフンで始まるパターンも検索可能。
  
-- 
-- Name: SATOH Fumiyasu @ OSS Technology Corp. (fumiyas @ osstech co jp)
-- Business Home: http://www.OSSTech.co.jp/
-- GitHub Home: https://GitHub.com/fumiyas/
-- PGP Fingerprint: BBE1 A1C9 525A 292E 6729  CDEC ADC2 9DCA 5E1C CBCA

-- 
Unsubscribe instructions: E-mail to [email protected]
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/ja/discuss/
All messages sent to this list will be publicly archived and cannot be deleted

メールによる返信