zsh-users
 help / color / mirror / code / Atom feed
* FNG optional presecence of a character
@ 2006-02-22 21:26 zzapper
  2006-02-22 21:29 ` Clint Adams
  0 siblings, 1 reply; 3+ messages in thread
From: zzapper @ 2006-02-22 21:26 UTC (permalink / raw)
  To: zsh-users

Hi

Just a bit of FNG, and hope i'm not having a blond moment

I want to be able to list

_fred.php
fred.php


I know I can do a clumsy

ls [_f][fr]*.php

I'd be interested in both a bash and or zsh solution

-- 
zzapper
Success for Techies
http://SuccessTheory.com/tips/ vim, zsh & success tips



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: FNG optional presecence of a character
  2006-02-22 21:26 FNG optional presecence of a character zzapper
@ 2006-02-22 21:29 ` Clint Adams
  2006-02-22 21:53   ` Dan Nelson
  0 siblings, 1 reply; 3+ messages in thread
From: Clint Adams @ 2006-02-22 21:29 UTC (permalink / raw)
  To: zzapper; +Cc: zsh-users

> _fred.php
> fred.php
> 
> 
> I know I can do a clumsy
> 
> ls [_f][fr]*.php

ls {_,}fred.php


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: FNG optional presecence of a character
  2006-02-22 21:29 ` Clint Adams
@ 2006-02-22 21:53   ` Dan Nelson
  0 siblings, 0 replies; 3+ messages in thread
From: Dan Nelson @ 2006-02-22 21:53 UTC (permalink / raw)
  To: zzapper, zsh-users

In the last episode (Feb 22), Clint Adams said:
> > _fred.php
> > fred.php
> > 
> > I know I can do a clumsy
> > 
> > ls [_f][fr]*.php
> 
> ls {_,}fred.php

Not strictly the same, since that's brace expansion, not globbing. 
This is the equivalent glob pattern (match _ or the empty string):

ls (_|)fred.php

-- 
	Dan Nelson
	dnelson@allantgroup.com


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-02-22 21:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-22 21:26 FNG optional presecence of a character zzapper
2006-02-22 21:29 ` Clint Adams
2006-02-22 21:53   ` Dan Nelson

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).