command to copy hidden files?
Les Mikesell
lesmikesell at gmail.com
Wed Jan 24 02:58:08 UTC 2007
Les wrote:
>>> I've tried to copy files from my home folder to do a disk upgrade. I
>>> foolishly only copied the visible (non-dot) files. Now I'd like to copy
>>> only the . files (recursively) but don't see what the syntax is. Anyone?
>>>
>> In case the filenames of the dot files have a length of 3 or more you can use:
>>
>> cp .??* target
>>
>>
> Wouldn't TAR manage this better? or perhaps dd?
>
Let cp's recursion handle it if you want the whole directory:
cd targetdir
cp -av . destdir
or
rsync -av . destdir
The later can be repeated quickly, taking only the changes since the
last run.
--
Les Mikesell
lesmikesell at gmail.com
More information about the users
mailing list