TestPhoenixLiveView/flake.nix
2024-03-08 20:00:46 +01:00

34 lines
905 B
Nix

{
description = "Test Phoenix Live View";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
customElixir = pkgs.elixir_1_16.override {
erlang = pkgs.erlang_26;
};
basePackages = [
customElixir
pkgs.git
];
buildInputs = basePackages
++ pkgs.lib.optionals pkgs.stdenv.isLinux [ pkgs.inotify-tools ]
++ pkgs.lib.optionals pkgs.stdenv.isDarwin (with pkgs.darwin.apple_sdk.frameworks; [ pkgs.CoreFoundation pkgs.CoreServices ]);
in
{
devShells = rec {
default = pkgs.mkShell {
buildInputs = buildInputs;
};
};
});
}