here document in shell script example
Example: bash here document example
cat << EOF > file.txt
The current working directory is: $PWD
You are logged in as: $(whoami)
EOF
cat << EOF > file.txt
The current working directory is: $PWD
You are logged in as: $(whoami)
EOF