You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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 to https://github.com/Behat/Behat/releases/download/v3.8.1/behat.phar
The text was updated successfully, but these errors were encountered:
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...
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
The text was updated successfully, but these errors were encountered: