# How to change a name of cloud directory?

How to change a name of cloud directory? Such as \$CloudRootDirectory will give an ugly, long and illegible directory name. How to change the name to be my custom? You can see,there are some meaningless and unreadable names in my CloudDirectory.

CloudEvaluate[
g = NestGraph[Select[FileNames["*", #], DirectoryQ] &, Directory[],
2]; Graph[g,
VertexLabels ->
Table[a -> Placed[FileNameTake[a], Center], {a, VertexList[g]}]]]


• Are you looking to set a custom name for your cloud objects? – ktm Oct 2 '16 at 19:25
• @user6014 Can you?And for that cloud root directory? – yode Oct 2 '16 at 19:29
• I'm not sure... It seems to be very poorly documented. I just wanted to ensure I was understanding the question correctly. While I was looking into it. – ktm Oct 2 '16 at 19:35
• @yode you can use URLShorten, is that what you need? – Kuba Oct 4 '16 at 18:36
• @Kuba The cloud fold have its name.I want to change it sometime.Like the local function RenameDirectory. – yode Oct 4 '16 at 20:42

You can't rename your root directory or get rid of unreadable sequences in the url because there has to be something automatically distinctive for each user.

You can rename deeper directories though. RenameDirectory does not work but you can use RenameFile analogously to: How to apply RenameFile to a CloudObject

co = CloudDeploy[FormFunction[{"x" -> "Integer"}, #x! &], "dir/form"]

CloudObject[https://www.wolframcloud.com/objects/user-.../dir/form]

RenameFile[
CloudObject["dir"],
CloudObject["anotherDir"]
]

CloudObject["https://www.wolframcloud.com/objects/user-.../anotherDir"]


And confirmation that the original file is there:

CloudObjectInformation[#, "Path"] & /@ CloudObjects["anotherDir"]

{"user-.../anotherDir/form"}

• You have earned the bounties going to be expired. :) – yode Oct 9 '16 at 18:08
• @yode thanks, I'm glad it is helpful. – Kuba Oct 9 '16 at 18:09
• We achieve it eventually,but it's seem unreasonable.A folder in cloud is not a CloudObject I think.Such as you cannot find a folder by CloudObjects.How do you think? – yode Oct 9 '16 at 18:20
• I'm not sure what do you mean. But yes, directory doesn't seem to be a CloudObject but we can use this wrapper to not type full path and so that RenameFIle knows it should call the Cloud. – Kuba Oct 9 '16 at 18:24