用mv遍历三点目录 [英] Three dots directory traversal with mv

查看:71
本文介绍了用mv遍历三点目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果执行以下命令,文件会去哪里:

Where does the file go if you execute the following command:

mv <file> ...

请注意,没有名称为的目录... 在当前目录中。

Note that there is no directory with the name ... in the current directory.

推荐答案

可能没有名称为 ... 在当前目录中,但是您正在使用该名称创建文件。 (因为它以开头。,所以被隐藏了。)

There may be no directory with the name ... in the current directory, but you're creating a file with that name. (Because it starts with a ., it's hidden).

如果使用 -a 自变量 ls

$ ls -a
.  ..
$ touch file; mv file ...; ls -a
.  ..  ...

这篇关于用mv遍历三点目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆