Open heiglandreas opened 3 years ago
The issue seems also to be that the URL https://github.com/Behat/Behat/releases/download/v3.8.1/behat.phar
also does not match the regex as the regex exptects either *-major.minor.patch*
or /major.minor.patch/
. But the /v3.8.1/
doesn't match either...
sigh
Currently
getPharVersion
tries to get the actual PHAR-Version from the provided URL.If one uses a service that resolves a certain version-constraint and then redirects to the last version matching that constraint the provided URL might not match the regular expressions in that function and result in an inabillity to install the tool.
Either we need to make these regexes much mor elax or resolve the regex after following all redirects to the final download URL and then apply those regexes to that final URL.
Concrete case is that I'm not able to install via
phive install "https://api.getlatestassets.com/github/Behat/Behat/behat.phar?version=^3.0"
which resolves tohttps://github.com/Behat/Behat/releases/download/v3.8.1/behat.phar