I have a Podspec and I want to change the version in that file using sed and regex. the line is below
s.version (ignore spaces) = (ignore spaces) "x.x.x"
What would be the exact sed command to change this version.
I have a Podspec and I want to change the version in that file using sed and regex. the line is below
s.version (ignore spaces) = (ignore spaces) "x.x.x"
What would be the exact sed command to change this version.
Simply use
~$ sed 's/^\(s.version *= *\)"[^"]*"/\1"a.b.c"/' myfile
You can use the -i
option to modify in place the file.