bash
3日前の日付を知りたい時は $ date --date '3 days ago' こんなことが実はできる
if ls | grep test > /dev/null;then echo 'testって文字列が入ったファイルがありました。' fi
count=0 let count=${count}+1 シェルスクリプトでは数値は存在しない(全て文字列)なので四則演算が煩わしい。
ファイルの数 $ find -type f |egrep '\.([chp](xx|pp)*|cc|hh)$'|wc -l それらの行数 $ find -type f | egrep '\.([chp](xx|pp)*|cc|hh)$' | xargs wc -l