grep output placed into a while loop
问题 I currently have my grep output configured to place everything in a file, i'm trying to set something up where a file will not need to be created. func_database () { egrep "^[0-9]" file.txt | egrep "/ON /" | sed s/-[^@]*$// > /users/home/myhome/log/test.txt } func_database while read -r line ; do echo "Database $line Area a:" python amgr.py status $line a echo "" echo "Database $line Area b:" python amgr.py status $line b echo "" echo "Database $line Area c:" python amgr.py status $line c