example08.42
来自「UNIX[1].shell范例精解(第4版)_code」· 42 代码 · 共 13 行
42
13 行
#!/bin/sh# This program demonstrates the scope of variables when # assigned within loops where the looping command uses # redirection. A subshell is started when the loop uses # redirection, making all variables created within the loop # local to the shell where the loop is being executed.while read linedo echo $line # This line will be redirected to outfile name=JOEdone < testing > outfile # Redirection of input and outputecho Hi there $name
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?