shell

ディレクトリ以下にあるファイルをUTF8-BOMへエンコードする

以下のコマンドを実行すると、カレント以下の.cファイルと.hファイルが、UTF8(BOM付き)にエンコードされる。 find -exec は条件にマッチしたファイル毎にコマンドを適用できるオプション。 # find . -type f \( -name \*.c -o -name \*.h \) -exec nkf --ove…

日付の取得

メモ。 DATE=`date+%Y%m%d`

unset

exportした環境変数を削除するには 、unset コマンドを使う。 % unset http_proxy % printenv