I need to get the version number of a program from the following output:
~$ pyrcc5 -version
pyrcc5 v5.15.0
~$
Now I thought cut
could do the job:
~$ pyrcc5 -version | cut -f2 -d"v"
pyrcc5 v5.15.0
~$
But it doesn't cut away anything ?!?
~$ echo $(pyrcc5 -version) | cut -f2 -d"v"
pyrcc5 v5.15.0
~$
Even worse … Expected output would be
5.15.0