Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: letter sequences



On Thu, Dec 06, 2007 at 12:01:11PM +0100, Baptiste Daroussin wrote:
> I'd like to get a sequence of letter in the same way as we can get a 
> sequence of numbers in zsh :
> $ echo {04..10}
> 04 05 06 07 08 09 10
>
> but for letters :
> $ echo {a..n}
> . a n
[...]

~$ setopt braceccl

(which apparently you have already)

~$ echo {a-n}
a b c d e f g h i j k l m n

also:

~$ c=({$'\0'-$'\377'})
~$ echo $c[(r)a,(r)n]

-- 
Stephane



Messages sorted by: Reverse Date, Date, Thread, Author