I'm trying to get the version number out of a string which looks like this:
[7:38:06 PM] [semantic-release] › ℹ Running semantic-release version 17.1.2
[7:38:09 PM] [semantic-release] › ✔ Published release 1.0.7 on default channel
As I need to do this in BusyBox, I can't use grep with the -P option:
grep -oP 'Published release \K.*? '
So I tried to use sed, but my attempt doesn't return anything:
sed -n 's/.*Published release (.*) .*/\1/p'
What is wrong with this command or is there a 'native' solution to get 1.0.7?