nix/templates/godot/flake.nix

33 lines
728 B
Nix
Raw Normal View History

{
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
outputs = {
self,
nixpkgs,
...
}: let
inherit (self) outputs;
2024-03-19 10:25:29 -05:00
supportedSystems = [
"x86_64-linux"
2024-03-19 10:25:29 -05:00
"aarch64-linux"
"x86_64-darwin"
"aarch64-darwin"
];
2024-03-19 10:25:29 -05:00
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
in {
devShells = forAllSystems (system: let
pkgs = import nixpkgs {inherit system;};
in {
default = outputs.devShells.${system}.godot;
godot = pkgs.mkShell {
buildInputs = with pkgs; [godot_4 gdtoolkit];
shellHook = ''
echo -e "\e[0;30m\e[43m Use 'godot4 -e' to run the editor for this project. \e[0;30m\e[0m"
'';
};
});
};
}