From owner-freebsd-current Sat May 18 20:23:35 2002 Delivered-To: freebsd-current@freebsd.org Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by hub.freebsd.org (Postfix) with ESMTP id 5B4B337B413 for ; Sat, 18 May 2002 20:23:33 -0700 (PDT) Received: from hades.hell.gr (patr530-b181.otenet.gr [212.205.244.189]) by mailsrv.otenet.gr (8.12.3/8.12.3) with ESMTP id g4J3NNQJ005089; Sun, 19 May 2002 06:23:24 +0300 (EEST) Received: from hades.hell.gr (hades [127.0.0.1]) by hades.hell.gr (8.12.3/8.12.3) with ESMTP id g4J3NNIu016102; Sun, 19 May 2002 06:23:23 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Received: (from charon@localhost) by hades.hell.gr (8.12.3/8.12.3/Submit) id g4J3NMv1016101; Sun, 19 May 2002 06:23:22 +0300 (EEST) (envelope-from keramida@ceid.upatras.gr) Date: Sun, 19 May 2002 06:23:22 +0300 From: Giorgos Keramidas To: "Benjamin P. Grubin" Cc: current@FreeBSD.ORG Subject: Re: mergemaster(8) broken -- uses Perl Message-ID: <20020519032321.GA15987@hades.hell.gr> References: <20020519022922.GA10039@hades.hell.gr> <000301c1fee2$dc221650$080aa8c0@VINZCLORTHO> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <000301c1fee2$dc221650$080aa8c0@VINZCLORTHO> User-Agent: Mutt/1.3.99i Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 2002-05-18 23:11, Benjamin P. Grubin wrote: > Giorgos Keramidas wrote: > > > > [ The above should print in stdout just 01777 as a number. ] > > ... > > Does anyone know of any other (possibly more elegant way) of > > reading the numeric value of the permission bits for a file? > > Is [t]csh's `filetest` builtin viable here? Ah, very good hint. Unfortunately even with -P: I can't get the `special' bits like sticky, etc. as I can see: $ /bin/tcsh -c 'filetest -P: /tmp' 0777 and mergemaster.sh uses this as an argument to `install -m num' to set the mode of installed files :-/ - Giorgos [ That was a VERY good hint, BTW. I didn't know about `filetest' and it seems a rather useful feature of tcsh. ] To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message