Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have mounted the USB and have successfully accessed it. On the USB are files and directories with files within them as well as .htaccess files.

I know that the terminal can't see the .htaccess files since everything in ubuntu starting with . is hidden. However, I can see them on the GUI if I enable Show Hidden Files.

Anyways, my question is, how do I copy EVERYTHING, including the .htaccess and directories while keeping the structure intact as it is on the USB to /var/www


share|improve this question
Although .htaccess is hidden it will still be copied using the cp -R command. (R for recursive). To see it in the terminal you can type "ls -al" – Christian Skjødt Feb 7 '12 at 12:43

Like the comment above says, cp -r will copy it, so just run cp -r /media/<usb-name> /path/to/target

share|improve this answer

To use a GUI type:

Alt F2

then enter:

gksu nautilus

You can then show hidden files and copy them.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.