delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/12/13/04:15:09.1

From: eplmst AT lu DOT erisoft DOT se (Martin Stromberg)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Bug in command-line globbing
Date: 13 Dec 2002 08:18:26 GMT
Organization: Ericsson Erisoft AB, Sweden
Lines: 20
Message-ID: <atc54i$m3m$2@antares.lu.erisoft.se>
References: <Pine DOT GSO DOT 4 DOT 44L-027 DOT 0212122304010 DOT 23682-100000 AT unix14 DOT andrew DOT cmu DOT edu>
NNTP-Posting-Host: lws256.lu.erisoft.se
X-Newsreader: TIN [version 1.2 PL2]
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Arthur J. O'Dwyer (ajo AT andrew DOT cmu DOT edu) wrote:
: > If you are writing a tr-clone, your best bet might be to disable globbing
: > (i think this is not so bad since globbing is meant to work with file
: > names).

: Yeah, that's what I've done as a stopgap measure.  But it would be
: nice if globbing worked correctly, so one could invoke a program as

: % tr -d '*\' *.txt

: and have it work as expected.  I don't know why I'd want to delete all

You can, with some extra work. 1. Disable globbing as described so
far. 2. When you find an argument that isn't an option (i. e. a file
name) call glob() on it.


Right,

						MartinS

- Raw text -


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