this post was submitted on 21 Sep 2023
51 points (100.0% liked)

Free and Open Source Software

17520 readers
283 users here now

If it's free and open source and it's also software, it can be discussed here. Subcommunity of Technology.


This community's icon was made by Aaron Schneider, under the CC-BY-NC-SA 4.0 license.

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] marco@beehaw.org 4 points 9 months ago* (last edited 9 months ago) (2 children)

It's cool, I just gave it a go, but I'm not sure it's gonna happen that I'll transition from

ls -lrt (this does not work in NuShell)

to

ls | sort-by modified | reverse

[–] starman@programming.dev 4 points 9 months ago (2 children)

Well, it's easier to remember second script

[–] FUsername@feddit.de 6 points 9 months ago

While your argument is valid, most bash users I know are lazy bitches and tend to alias commands which require to type more than 5 letters. I guess NuShell lower the bar for NuUsers, but of I have to remember either single letters or puppy it through longer commands, I world opt for single letters.

[–] marco@beehaw.org 2 points 9 months ago

Totally - for new users it's great... similarly, I would have loved to start typing on Dvorak.

My problem might be one of age, but there is no way I'm gonna retrain myself after 20+ years of typing that specific ls command... ;)

[–] hallettj@beehaw.org 2 points 9 months ago

So maybe this is too much of a kludge, but I happened to see that you can define custom sub-commands to extend existing commands. You can use that to reproduce your familiar command:

def "ls -lrt" [] {
  ls | sort-by modified | reverse
}

Of course this does not capture the usual composability of those switches.