Am I perhaps a genius or is it just not that difficult to know two tools?
Am I perhaps a genius or is it just not that difficult to know two tools?
I've been using `exa` for years, and my aliases work regardless if it's installed or not. I just get a better UX if it is.
Huh. I always use plain ls with flags and deliberately unset aliases like ll.
I guess I'm weird.
Here are my aliases:
if type exa >/dev/null 2>&1; then
alias l='exa -alg --color=always --group-directories-first --git'
alias ll='exa -aliSgh --color=always --group-directories-first --git'
alias lt='exa -@alT --color=always --git'
alias lr='exa -alg --sort=modified --color=always --group-directories-first --git'
else
alias l='ls -alh --group-directories-first'
alias ll='ls -al --group-directories-first'
alias lr='ls -ltrh --group-directories-first'
fi
I still retain `ls -ltrh` in my muscle memory, but after years of typing it, `lr` has saved me a lot of time and effort.Aliases are not just a way to type less. They also serve as a way to define configuration. If I ever need to tweak the output for all my usage of `ls`, I can just add it to all aliases, as I've done for `--group-directories-first`.
The “inertial hump,” the learning curve, is going to be like 30 minutes, if you take 15 of those minutes to eat a sandwich.
If you want to reduce it even more, do this:
1. Install new tool.
2. In your .bashrc define some flag combinations that make it even more like your use of old tool, with similar-sounding aliases or even ones commonly used for old tool.
3. Now in the unlikely scenario that new tool goes away, you’ll still be current w old tool from those lookalike commands.
> "\" compared to "/"
Powershell :)