Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

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

Thanks

share|improve this question
2  
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
add comment

2 Answers 2

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
add comment

To use a GUI type:

Alt F2

then enter:

gksu nautilus

You can then show hidden files and copy them.

share|improve this answer
add comment

Your Answer

 
discard

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.