对shell中cat 和EOF的理解
2015-07-09 15:03
936 查看
下载我们在linux文本界面下测试下
$cat hao.c
$wo mei you chi fan
$cat > hao.c << EOF
>where are you
>EOF
再次cat hao.c 出现
where are you
可以看出被覆盖了
但是如果输入如下命令:
$cat >> hao.c << EOF
输出的结果是:
wo mei you chi fan
where are you
$cat hao.c
$wo mei you chi fan
$cat > hao.c << EOF
>where are you
>EOF
再次cat hao.c 出现
where are you
可以看出被覆盖了
但是如果输入如下命令:
$cat >> hao.c << EOF
输出的结果是:
wo mei you chi fan
where are you
相关文章推荐
- 一个不错的shell 脚本教程 入门级
- shell 时间 循环
- shell脚本中的特殊用法
- Linux学习笔记(11)——bash
- shell函数
- shell工具
- 基本SHELL语句总结【20150709】
- SharePoint自动化系列——Set MMS field value using PowerShell.
- windows下使用xShell向远程linux上传文件
- bash 快捷键
- linux shell中 if else以及大于、小于、等于逻辑表达式介绍
- 70个shell常用操作、 shell编程控制结构:expr、let、for、while、until、shift、if、case、break、continue、函数、select
- 数据库定期备份shell
- Android执行shell命令(top查看CPU信息)
- shell 监控磁盘使用率
- linux中shell变量$#,$@,$0,$1,$2的含义解释
- 如何编写shell脚本
- shell 脚本的执行
- Xshell使用技巧(二)
- Shell时间运算及时间差计算方法