How do you move an entire directory in the /root

Asked by Manmetal

How do you move an entire directory in the /root with files in them?

I am trying to copy a entire directory in the /root to another location outside of the root so I must use the command line but I can only copy the files and not the sub directories from the target directory.

i.e. sudo cp /opt/joomla/ *.* /opt/xampp

I only get the files not the directories in the folder

Thanks,

Jerry

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Wrwrwr (wrwrwr) said :
#1

sudo cp -r /opt/joomla /opt/xampp

-r (-R or --recursive) can be used with many other commands

Use "mv" instead of "cp" if you want to rename.

Can you help with this problem?

Provide an answer of your own, or ask Manmetal for more information if necessary.

To post a message you must log in.