44 lines
1.3 KiB
Nix
44 lines
1.3 KiB
Nix
|
{
|
||
|
description = "cellular automata experiments written in lua with löve";
|
||
|
|
||
|
inputs = {
|
||
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||
|
flake-parts.url = "github:hercules-ci/flake-parts";
|
||
|
flake-parts.inputs.nixpkgs.follows = "nixpkgs";
|
||
|
};
|
||
|
|
||
|
outputs = { self, flake-parts, ... }:
|
||
|
flake-parts.lib.mkFlake { inherit self; } {
|
||
|
imports = [ ];
|
||
|
systems = [ "x86_64-linux" "aarch64-darwin" ];
|
||
|
perSystem = { config, self', inputs', pkgs, system, ... }: {
|
||
|
devShells.default = pkgs.mkShell {
|
||
|
name = "love";
|
||
|
packages =
|
||
|
let
|
||
|
love = pkgs.stdenv.mkDerivation {
|
||
|
pname = "love";
|
||
|
version = "11.4";
|
||
|
|
||
|
src = pkgs.fetchzip {
|
||
|
url = "https://github.com/love2d/love/releases/download/11.4/love-11.4-macos.zip";
|
||
|
sha256 = "sha256-1YZVh0fl1sSpdEk+NR+J2IJ6G0rYXwdEuhBPJjhxx5o=";
|
||
|
};
|
||
|
|
||
|
dontBuild = true;
|
||
|
|
||
|
installPhase = ''
|
||
|
mkdir -p $out/bin
|
||
|
cp -r . $out/love.app
|
||
|
ln -s $out/love.app/Contents/MacOS/love $out/bin/love
|
||
|
'';
|
||
|
|
||
|
meta.platforms = pkgs.lib.platforms.darwin;
|
||
|
};
|
||
|
in
|
||
|
[ love ];
|
||
|
};
|
||
|
};
|
||
|
};
|
||
|
}
|