shell IFS 2021-06-17 Source Edit History 利用环境变量IFS自定义分隔符 Catalogue 12345678910111213$ cat test.txt apple pear banana orange $ cat test.sh#!/bin/bashifs_old=$IFSIFS=$'\n'for val in `cat test.txt`do echo "n=$val"doneIFS=$ifs_old$ ./test.shn=apple pear banana orange