main logo
Subject: Re: [ProLinux] cp command
Author: Vince Teachout
Posted: 2008/04/30 10:27:57
 
View Entire Thread
New Search


Carl Karsten wrote:
> Peter Cushing wrote:
>
>> Hi All,
>>
>> Just been using knoppix 5.1 to try to get some stuff off a laptop before
>> reinstalling/repairing windows. Booted up fine and found the documents
>> and settings/xxx user/ folder and put in a memory stick to copy to.
>> Unfortunately when I marked the contents of the folder and copied, then
>> pasted onto the stick it seemed to take an age going through the folders
>> before even starting the copy. After a while I brought up a console and
>> cd'd to the correct folder //media/hda2/etc..
>> I wanted to just copy the entire contents including subfolders to the
>> stick with (I think):
>>
>> cp -R *.* //media/sda1
>>
>>
>> Trouble is this only copied the main folder and not the subfolders.
>>
>
> I bet your sub folders did not have a dot in them.
>
> cp -R * //media/sda1
>
> * matches everything. *.* matches with a . somewhere between 2 sets of everythings.
>
> I have no idea why *.* works the way it does in dos.
>
>
I do - DOS considers "file.ext" to be 2 separate parts of a filename.
*.* matches "Any name and Any extension" *.foo just matches "Any name
with the foo extension"
Plus, Linux is just cooler, so does everything better.



 
©2008 Vince Teachout
<-- Prior Message New Search Next Message -->