A custom bash "type" command with recursive alias and symlink resolution

sebastiancarlos@lemmy.sdf.org to Linux@lemmy.ml – 29 points –
Find literally everything about every command available in Bash #commandline #code #linux #shell
youtube.com
5

Hummmm regex, it would be possible to code this in awk I think

I thought about it but there are two complications here: The code is recursive, and it calls an external shell script. I'm sure there are ways to do that in awk, but I'm not too much of an awk guru, so I decided to leave my awking to self-contained smaller scripts. Also, considering I need to spawn subprocesses anyway for this, Bash wouldn't be a bad choice since it's built for that.