LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 768|回复: 2

How to read a file line by line and send out as fixed format ?

[复制链接]
发表于 2005-6-3 15:25:50 | 显示全部楼层 |阅读模式
Hi, I have one file: list.txt
----------
$cat list.txt
AA   303
BB   301
BC   104
AD   203
..   ..
..   ..
----------
IF i already have a function: mbxsend mailbox111 "name=AA, dest=BB"
Then AA , BB will be received at mailbox111.

How can I read the file list.txt line by line and send out the message for every line using the format?

Thanks for the help,  any idea will be appreciated.
发表于 2005-6-3 19:34:36 | 显示全部楼层
谁给翻译一下
回复 支持 反对

使用道具 举报

发表于 2005-6-3 23:49:24 | 显示全部楼层
Post by loosy929
Hi, I have one file: list.txt
----------
$cat list.txt
AA   303
BB   301
BC   104
AD   203
..   ..
..   ..
----------
IF i already have a function: mbxsend mailbox111 "name=AA, dest=BB"
Then AA , BB will be received at mailbox111.

How can I read the file list.txt line by line and send out the message for every line using the format?

Thanks for the help,  any idea will be appreciated.


read
不行吗? ;)

烈火大哥越来越幽默了.
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表