Closed dezza closed 2 years ago
Polyphony fails to build if uname -sr is not formed a certain way
uname -sr
Current regex requires:
Other samples I found:
Linux 5.10.60.1-microsoft-standard-WSL2
-
Linux 5.10.63+
I propose: Linux (\d)\.(\d+)(?:\.)?((?:\d+\.?)*)(?:\-)?([\w\-]+)?
Linux (\d)\.(\d+)(?:\.)?((?:\d+\.?)*)(?:\-)?([\w\-]+)?
Which will match on: Linux 5.10.63.62.63, infinite patch numbers Linux 5.10.60.1-microsoft-standard-WSL2, word at the end including -
Linux 5.10.63.62.63
Test: https://regex101.com/r/CLX00x/1
Out of curiosity, why did you close the PR? This seems like a valuable change. Nevermind, I now see your other PR #89.
Polyphony fails to build if
uname -sr
is not formed a certain wayCurrent regex requires:
Other samples I found:
Linux 5.10.60.1-microsoft-standard-WSL2
(Windows Subsystem for Linux), includes-
in word.Linux 5.10.63+
(raspbian), no word presentI propose:
Linux (\d)\.(\d+)(?:\.)?((?:\d+\.?)*)(?:\-)?([\w\-]+)?
Which will match on:
Linux 5.10.63.62.63
, infinite patch numbersLinux 5.10.60.1-microsoft-standard-WSL2
, word at the end including-
Test: https://regex101.com/r/CLX00x/1