Sed script to update a version number in an RPM SPECS file
Variables don't interpolate inside single quotes.  You need double quotes.

No need to capture the old version that we're throwing away. The /g is redundant since the pattern can never match more than once per line (being anchored to start-of-line).

What happens with Version: 0.9a?  Version:1?  Version:?  Better to take the whole line, possibly excluding comments, and relax the space requirement.  

sed -ri "s/^(Version:\s*)[^#]*/\1$version/" SPECS/*.spec


It's possible for the description or another section to contain the trigger text, and we probably don't want to change that.  Use sed's start,stop addressing to limit replacement to the top block only, stopping at the first %whatever header:

sed -ri "1,/^\s*%/s/^(Version:\s*)[^#]*/\1$version/" SPECS/*.spec