From d95fd0853a4d70bf604bb7c4ce117a750e40f592 Mon Sep 17 00:00:00 2001 From: Antonio Nuno Monteiro Date: Thu, 15 Aug 2024 19:05:10 -0700 Subject: [PATCH] fix nix workflow --- .github/workflows/nix.yml | 2 +- flake.lock | 79 +++++++-------------------------------- flake.nix | 17 ++++----- 3 files changed, 21 insertions(+), 77 deletions(-) diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml index 027cd64..0588689 100644 --- a/.github/workflows/nix.yml +++ b/.github/workflows/nix.yml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - ocamlVersion: [5_1] + ocamlVersion: [5_2] steps: - uses: actions/checkout@v2 - uses: cachix/install-nix-action@v21 diff --git a/flake.lock b/flake.lock index e50441d..490b2f9 100644 --- a/flake.lock +++ b/flake.lock @@ -5,11 +5,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1705309234, - "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -18,65 +18,13 @@ "type": "github" } }, - "melange-compiler-libs": { - "inputs": { - "flake-utils": [ - "melange-src", - "flake-utils" - ], - "nixpkgs": [ - "melange-src", - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1705466801, - "narHash": "sha256-1dub8rJZkAjZiKR0EopdXVP3JCbSq/8fAw2Fei0Hh+E=", - "owner": "melange-re", - "repo": "melange-compiler-libs", - "rev": "87bb98024b1669766f9c8aec3bbbf73ef332dcb6", - "type": "github" - }, - "original": { - "owner": "melange-re", - "repo": "melange-compiler-libs", - "type": "github" - } - }, - "melange-src": { - "inputs": { - "flake-utils": [ - "flake-utils" - ], - "melange-compiler-libs": "melange-compiler-libs", - "nix-filter": [ - "nix-filter" - ], - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1706823522, - "narHash": "sha256-LsqXADoVR4T8V1xH2z6rwz/DPJ1epI5u1/eRElwNHKg=", - "owner": "melange-re", - "repo": "melange", - "rev": "09aa67bdc69e92610b25cef7386965deb21df00b", - "type": "github" - }, - "original": { - "owner": "melange-re", - "repo": "melange", - "type": "github" - } - }, "nix-filter": { "locked": { - "lastModified": 1705332318, - "narHash": "sha256-kcw1yFeJe9N4PjQji9ZeX47jg0p9A0DuU4djKvg1a7I=", + "lastModified": 1710156097, + "narHash": "sha256-1Wvk8UP7PXdf8bCCaEoMnOT1qe5/Duqgj+rL8sRQsSM=", "owner": "numtide", "repo": "nix-filter", - "rev": "3449dc925982ad46246cfc36469baf66e1b64f17", + "rev": "3342559a24e85fc164b295c3444e8a139924675b", "type": "github" }, "original": { @@ -93,11 +41,11 @@ "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1706981273, - "narHash": "sha256-LEZ88+gp1QKXO7QlLYO/lONWfv7efWGsj62iMBre0Xw=", + "lastModified": 1723692471, + "narHash": "sha256-+abV/e3WBfmraqVNqq357w3NMFAPzizZwKLVB3+9vLQ=", "owner": "nix-ocaml", "repo": "nix-overlays", - "rev": "b037df8dbce2708cd68cc09ad0268fb0c49bd8fe", + "rev": "c8d3c3276e1719fc49628fc6756bd92ffe91be41", "type": "github" }, "original": { @@ -108,24 +56,23 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1706941790, - "narHash": "sha256-V4apg6WJS6hc1VhHuUpaLt0r/ulu/hvFruP6NKdEdfo=", + "lastModified": 1723418128, + "narHash": "sha256-k1pEqsnB6ikZyasXbtV6A9akPZMKlsyENPDUA6PXoJo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4f301350dacb4eb0a93578ef3b07c8a996c777e7", + "rev": "129f579cbb5b4c1ad258fd96bdfb78eb14802727", "type": "github" }, "original": { "owner": "NixOS", "repo": "nixpkgs", - "rev": "4f301350dacb4eb0a93578ef3b07c8a996c777e7", + "rev": "129f579cbb5b4c1ad258fd96bdfb78eb14802727", "type": "github" } }, "root": { "inputs": { "flake-utils": "flake-utils", - "melange-src": "melange-src", "nix-filter": "nix-filter", "nixpkgs": "nixpkgs" } diff --git a/flake.nix b/flake.nix index 51178fe..86cd9a7 100644 --- a/flake.nix +++ b/flake.nix @@ -7,21 +7,14 @@ url = "github:nix-ocaml/nix-overlays"; inputs.flake-utils.follows = "flake-utils"; }; - inputs.melange-src = { - url = "github:melange-re/melange"; - inputs.nix-filter.follows = "nix-filter"; - inputs.flake-utils.follows = "flake-utils"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - outputs = { self, nixpkgs, flake-utils, nix-filter, melange-src }: + outputs = { self, nixpkgs, flake-utils, nix-filter }: flake-utils.lib.eachDefaultSystem (system: let pkgs = nixpkgs.legacyPackages."${system}".appendOverlays [ (self: super: { - ocamlPackages = super.ocaml-ng.ocamlPackages_5_1; + ocamlPackages = super.ocaml-ng.ocamlPackages_5_2; }) - melange-src.overlays.default ]; inherit (pkgs) nodejs_latest lib stdenv darwin; @@ -31,7 +24,11 @@ src = ./.; nativeBuildInputs = with pkgs.ocamlPackages; [ melange ]; - propagatedBuildInputs = with pkgs.ocamlPackages; [ melange ]; + propagatedBuildInputs = with pkgs.ocamlPackages; [ + melange + yojson + ppxlib + ]; }; mkShell = { buildInputs ? [ ] }: pkgs.mkShell {