在Google云端存储中重命名文件? [英] renaming files in Google Cloud Storage?
本文介绍了在Google云端存储中重命名文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
您可以重新命名Google云端存储中的文件吗?
Can you rename files in Google Cloud Storage?
我让用户上传照片,但我想让他们能够编辑照片,至少改变他们上传的名字。我通过Node.js使用Javascript。
I am letting users upload photos, but I want to give them the ability to edit the photo, at least by changing the name they uploaded it with. I am using Javascript through Node.js.
谢谢!
Thanks!
推荐答案
这个命令:
gsutil mv gs://my_bucket/olddir gs://my_bucket/newdir
会完成这项工作。如果您有大量文件需要执行多处理移动,请使用以下命令:
will do the job. If you have a large number of files you need to do a multi-processing move, so use this command:
gsutil -m mv gs://my_bucket/olddir gs://my_bucket/newdir
您可以在文档中找到此信息。
You can find this information in the docs.
这篇关于在Google云端存储中重命名文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文