easy-purescript-nix icon indicating copy to clipboard operation
easy-purescript-nix copied to clipboard

Add flake.nix

Open ursi opened this issue 3 years ago • 5 comments

Just a simple flake that exposes the packages in this repo.

ursi avatar Apr 27 '21 01:04 ursi

Will the lockfile need a lot of updating?

toastal avatar Apr 27 '21 03:04 toastal

I don't think so. utils will never need to be updated, nixpkgs will need to be updated any time a newer version of some package is required. But I just realized the project already pins nixpkgs in pinned.nix, so I actually think using that is the way to go.

ursi avatar Apr 27 '21 03:04 ursi

alternatively, this can be used without a flake file as

{
  inputs = {
    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
    easy-purescript-nix = {
      url = "github:justinwoo/easy-purescript-nix";
      flake = false;
    };
  };
  
  outputs = { self, nixpkgs, easy-purescript-nix, ... }@inputs:
    let
      easy-ps = import easy-purescript-nix { inherit pkgs; };
    in
    {
      # ...
    };
}

toastal avatar May 25 '21 11:05 toastal

I think this merge request is worth looking at again. Flakes are no longer behind an experimental flag in unstable and in future versions of Nix.

toastal avatar Nov 12 '21 04:11 toastal

utils will never need to be updated,

It needs to be updated if you want to use a new set of defaults for eachDefaultSystem. For example, https://github.com/numtide/treefmt/pull/162 updated it to get aarch64-darwin in the list (added in https://github.com/numtide/flake-utils/commit/997f7efcb746a9c140ce1f13c72263189225f482).

srid avatar May 10 '22 22:05 srid

I definitely don't want to block this, but importing nixpkgs from the classic file makes stuff like inputs.easy-purescript.inputs.nixpkgs.follows = "nixpkgs"; impossible

voidus avatar Apr 19 '23 21:04 voidus

I no longer have interest in this PR.

ursi avatar Apr 19 '23 22:04 ursi