bashでファイルを読み込む
bashでファイルを1行ずつ読み込むにはwhile文で以下のように使用します。

#!/bin/bash

while read LINE; do
    echo $LINE
done > read_file
read_fileが読み込みたいファイル名です。上記はread_fileを1行ずつ読み込み、標準出力している例です。

Back to top

Information