delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/10/07/18:35:25

From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Hidden files
Date: Mon, 08 Oct 2001 00:23:38 +0200
Lines: 24
Message-ID: <3BC0D5EA.4D66AC38@is.elta.co.il>
References: <3BC0C2DF DOT AB756C49 AT lps DOT u-psud DOT fr>
NNTP-Posting-Host: 192.116.55.139
Mime-Version: 1.0
X-Trace: fu-berlin.de 1002493397 21398554 192.116.55.139 (16 [61365])
X-Mailer: Mozilla 4.7 [en] (Win98; I)
X-Accept-Language: en
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

"D. Taupin (wanadoo-lps)" wrote:
> 
> 1. Does the "ls" command give all files, including "hidden" files, as a
> standard?

It depends on what binary do you have.  It shouldn't list the hidden files
by default, but some ports have a bug and do show them.  "ls -a" should show
all the files, including hidden ones.

> 2. Does the expansion of * in commands include hidden files.

No.

> I ask that question in order to know whether a command like "zip" or
> "cp" wil/can/will not include hidden files.
> The reason of this question is to perform backups of some directories,
> INCLUDING hidden files (not done by pkzip for example).

You cannot count on hidden files to be included.  I suggest to ``unhide''
them all (with "attrib -h d:\foo\bar /s"), copy the tree, and then make the
files that were hidden be hidden again manually.

Note that ports of Unix utilities such as `cp' cannot copy hidden files as
hidden anyway; they can only copy them as read-only.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019