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

Re: possible 'is-at-least' bug?



On 2015-12-09 16:01:57 -0800, Bart Schaefer wrote:
> On Dec 7, 11:25am, Vincent Lefevre wrote:
> } Subject: Re: possible 'is-at-least' bug?
> }
> } On 2015-12-05 01:29:46 -0500, Benjamin R. Haskell wrote:
> } > `is-at-least` isn't intended to be that general.
> } > 
> } > To do so would require a great deal more complexity.
> } 
> } No, zsh already implements numeric sorting for the "n" parameter
> } expansion flag.
> 
> That's not the complexity he means.  Right now is-at-least splits up
> the string on dots and dashes by the simple expedient of setting $IFS.
> To also split "1a1" and "1b2" etc. on the non-space between the numbers
> and the letters, would require quite a bit more effort.

I meant that two such words could be compared without having to
split them, thanks to numeric sorting.

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



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