一品网
  • 首页

Shell中 heredoc 内容转义


1、在$符号前面加反斜杠,如:

cat > test.sh <

如果不加,将转成实际的值。

2、给EOF加个双引号,如:

cat > test.sh <<"EOF"
$test
EOF
系统运维bash

相关


linux bash array list

【linux系统】命令学习(八)bash 编程实战学习

切换到oracle用户的时候变成bash-3.2$

解决"-bash: netstat: command not found"问题

Bash命令 —— diff

Bash 命令 —— comm

(备忘录)002 --- bash xx.sh、sh xx.sh和./xx.sh的区别

如何使用 Python 或 Bash动态生成 Jekyll 配置文件

-bash: wget: command not found的两种解决方法

bash: lsof: command not found

Linux知识:/root/.bashrc与/etc/profile的异同

/bin/bash^M: 坏的解释器: 没有那个文件或目录

标签

一品网 冀ICP备14022925号-6