Post B4JGUlYtyp4x4ZB5SC by josevnz@fosstodon.org
 (DIR) More posts by josevnz@fosstodon.org
 (DIR) Post #B4HRy2LdMLfKi9DCJE by nixCraft@mastodon.social
       0 likes, 0 repeats
       
       Run the following to see your PATH settings in easy to read format on screen:```tr ":" "\n" <<<"$PATH" tr ":" "\n" <<<"$PATH"  | lolcat```This is a little more portable```echo "$PATH" | tr ":" "\n" echo "$PATH" | tr ":" "\n" | lolcat```#unix #linux
       
 (DIR) Post #B4HRy2l9pS59zJ9a5o by josevnz@fosstodon.org
       0 likes, 0 repeats
       
       @nixCraft Hi.I love tr but I love pure Bash even more:IFS=':' read -r -a path_parts <<< "$PATH"; printf '%s\n' "${path_parts[@]}"By the way, get ready for every opinionated sysadmin to post here, we are wired that way :-D Thanks for sharing.
       
 (DIR) Post #B4HRy3C6DHdJKrl65Q by JdeBP@tty0.social
       0 likes, 0 repeats
       
       @josevnz Looks complex.  (-:C shell:% printf '%s\n' $pathZ shell:% printf '%q\n' "$path[@]"#UnixShells #CShell #ZShell #zsh #csh
       
 (DIR) Post #B4HRy3XiusvkPvsMnA by lanodan@queer.hacktivis.me
       0 likes, 0 repeats
       
       @JdeBP @josevnz Yeah, IFS for just that makes it needlessly complex when it can also be like this:ksh, mksh, zsh: $ echo ${PATH//:/\\n}ksh, mksh, bash, yash, busybox sh, sash: $ echo "${PATH//:/$'\n'}"
       
 (DIR) Post #B4JGUlYtyp4x4ZB5SC by josevnz@fosstodon.org
       1 likes, 0 repeats
       
       @lanodan @JdeBP  Oh yeah, I forgot about the Bash regex substitution. Yeah, this is the best solution.