[英]Touch .env Won't Work, Touch anything.js Does
The Title pretty much sums this issue up, I am trying to create an .env file on my deployed EC2 instance by running touch .env
in the CLI for the deployment.标题几乎总结了这个问题,我试图通过在 CLI 中运行
touch .env
来在我部署的 EC2 实例上创建一个 .env 文件以进行部署。 The command returns no errors, indicating it created the file, but I cannot cd
into it, and it does not appear when I run ls
.该命令没有返回错误,表明它创建了文件,但我无法
cd
进入它,并且在我运行ls
时它没有出现。 It works totally fine if I try anything that isn't an .env file, so what gives?如果我尝试任何不是 .env 文件的东西,它完全可以正常工作,那么有什么用呢?
touch
is for creating an empty file, or updating the access and modification times of an existing file. touch
用于创建空文件,或更新现有文件的访问和修改时间。
cd
is for changing to a directory. cd
用于更改目录。 Don't try to cd
into a file, because that is never going to work.不要尝试
cd
进入文件,因为那永远行不通。
ls
without -a
does not show any files that start with a .
没有
-a
的ls
不显示任何以 . 开头的文件.
character.特点。
Try ls -a
to see if the .env
file exists.尝试
ls -a
查看.env
文件是否存在。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.