-
Notifications
You must be signed in to change notification settings - Fork 54
startsWith
(string) isn't appropriate for versions
#248
Comments
@sol Thanks for the pointer! (Which makes me think why I am maintaining another setup action; maybe it is more general by allowing to pick a You seem to have solved the same problems, and in a nice way; I was thinking of using the https://www.npmjs.com/package/compare-versions library for comparing versions, and maybe also its |
It's possible to install what you need with The main reason why I rolled my own back then was that I needed old versions of GHC that need to be That, and the fact that this repo includes multiple actions, which is broken in its own way (not only can't you publish anything to the marketplace, but it also makes it hard to version those actions independently).
As of now, I do set it manually (https://github.com/sol/hpack/blob/21480fd93c0538bf010bff1bc6d6f9d2f19f8653/.github/workflows/build.yml#L51), which is not ideal.
Given that the runner images already provide the latest version of GHC (which satisfies constraints of that form), I am puzzled when you would actually need something like this. |
|
Sooner than expected, the calamity strikes us: https://discourse.haskell.org/t/ann-stack-2-11-1/6287 Trying to add
Great to have the testsuite! |
actions/setup/src/opts.ts
Lines 97 to 99 in 1c618fb
Say the user requests
stack-version: 2.1
this will atm resolve to2.1.3
, according to the action's current consciousness about versions:actions/setup/src/versions.json
Lines 53 to 63 in 1c618fb
However, once we add stack version
2.11.1
, requesting2.1
will resolve to2.11.1
. Ooops!I suppose the proper ("Haskell") way to fix this to use a datatype for versions rather than mocking around with strings.
The text was updated successfully, but these errors were encountered: