-1

I have a directory I want to rename without spaces. This is the path to the file with spaces /home/ebank36/minecraft/The Fall of Gondolin.

I want to rename that directory to TFoG so I would like it to look like
/home/ebank36/minecraft/TFoG.

I need to do this so I can move a file out of that directory and place it in /home/ebank36/minecraft.

2 Answers 2

3

From a terminal, you could issue this command:

mv /home/ebank36/minecraft/The\ Fall\ of\ Gondolin /home/ebank36/minecraft/TFoG

(NOTICE the \ before the space. This is how bash knows the special character that follows the \ should be treated as part of the name)

Or, from a GUI, just click on that directory, press F2, and type the new name.

2
  • 1
    @ebank36 It should be noted that it's better to " quote the whole path rather than escaping individual space characters. Use this instead: mv "/home/ebank36/minecraft/The Fall of Gondolin" /home/ebank36/minecraft/TFoG
    – kiri
    Sep 15, 2013 at 23:49
  • Ok I will try and remember for future questions.
    – ebank36
    Sep 15, 2013 at 23:52
2

You can do this by opening the folder in the file manager, and then right clicking the folder and selecting "Rename", typing in the new folder name. The keyboard shortcut for renaming a selected file or folder, or several selected files or folders for a group rename, is F2. You may also use the command line.

2
  • sorry this won't help considering I do not have the desktop installed.
    – ebank36
    Sep 15, 2013 at 23:46
  • Oh - that wasn't clear in your question. You may see the link I provided.
    – Richard
    Sep 15, 2013 at 23:48

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .