larrypl
I think `N=/regex/ `should be `N=/string/`?
#3 · closed · 7 comments
I think `N=/regex/ `should be `N=/string/`?
Wow, I'd totally forgotten I ever wrote this. Amazingly it was exactly 10 years ago today! Thanks for the report; looking at the code, I think it should actually be `N=string`. I'll fix.
Thanks for the update! And the anniversary for csort!
You're welcome! How on earth did you find it, though, when I couldn't even remember it existed? :rofl:
I was looking for a way to sort dev, qa, stage, prod in that order (rather than dev, prod, qa, stage) and came across a stackexchange entry where you posted (10 years ago, IIRC) that you had written csort for that purpose. So now I can sort system names by their respective environments in logical order, because of csort! I'll find the entry if you're interested.
This is my use: ``` csort -t$'\t' 2:/^dev/ 1 2:/^qa/ 2 2:/^stage/ 3 2:/^prod/ 4 ```
Ah yes, found it: https://superuser.com/a/602918/104997 Again, zero recollection of this. I'm old enough that the internet has become the swap space for my brain :man_facepalming: :laughing:
Ha! Me too.