dylanaraps / pure-bash-bible

πŸ“– A collection of pure bash alternatives to external processes.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Regex [ Not an issue ] [ Help needed ]

Akianonymus opened this issue Β· comments

Can we use bash regex to match on multiple lines ?

For ex,

hello: one
hello: 2
Something: four
random: file

I want to extract just hello lines without grep, this may sound unnecessary, but just finding a way for the curious mind. πŸ˜€

Edit: Obviously without running a loop