同时移动文件和更改权限
在Linux中,当我使用mv时,新文件保留相同的权限。我想 mv 一个文件,但在移动之后,由新文件的所有者进行。这可能吗?
In Linux, when I use mv, the new file retains the same permissions. I would like to mv a file, but after the move, by the owner of the new file. Is this possible?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
同时是什么意思?为什么它很重要?这对你有用吗?
对于权限:
对于所有者:
What do you mean by simultaneous and why does it matter? Would this work for you?
For permissions:
For owner:
您可以在同一终端行中
mv
然后chown
该文件。请参阅按顺序执行多个命令。You can
mv
and thenchown
the file in the same terminal line. See Executing multiple command in sequence.