sysxplore
banner
sysxplore.bsky.social
sysxplore
@sysxplore.bsky.social
Everything about Linux🐧, DevOps, Networking, Automation, sysadmin🐱‍💻 & beginner tips💡Newsletter → sysxplore.substack.com
Want to learn Linux? Great! I'm writing a book to help you get started.

Join 500+ already on the waiting list:
firststepswithlinux.com
June 18, 2025 at 6:36 PM
Want to learn Linux? Great! I'm writing a book to help you get started.

Join 500+ already on the waiting list:
firststepswithlinux.com
June 18, 2025 at 6:35 PM
Another excellent method is to utilize shell parameter expansion to replace the ":" pattern with a newline ("n") string.

Here is the syntax:
${parameter//pattern/string}

Look at the example:
$ echo ${PATH//":"/"\n"}

// denotes replacing all instances of ":" with "\n".
June 18, 2025 at 6:35 PM