niv icon indicating copy to clipboard operation
niv copied to clipboard

Remove Unnecessary Uses of `rec`

Open sivizius opened this issue 2 years ago • 1 comments

This PR removes unnecessary usage of rec. This is not about rec sometimes considered an anti-pattern, this is about code, where this keyword can simply be removed. Because linters like statix complain, they have to configured to ignore sources.nix, which is somewhat annoying. This PR should fix that.

sivizius avatar Feb 01 '24 18:02 sivizius

EDIT: done

There's a test failure because Niv keeps track of the hashes of the different sources.nix versions:

 sources.nix
    has latest version:                   FAIL
      src/Niv/Sources/Test.hs:13:
      expected: "26ed55356db7673935329210a4f8c4a5"
       but got: "a8751de841ac5e0a60f4c2db7e8bbade"

if you want to have a go at it you can add a V29 in src/Niv/Sources.hs with hash "a87...", otherwise I'll have a look this evening!

nmattia avatar Feb 02 '24 10:02 nmattia

I do not understand the test failure or how this is related to my and your changes. Is there something I could do to finish this PR?

sivizius avatar Feb 21 '24 10:02 sivizius

It's unrelated. Thanks for the PR!

nmattia avatar Feb 21 '24 18:02 nmattia