Generalize dev/love2d.nix into dev/lua.nix
This commit is contained in:
parent
953c4c450b
commit
d56556b26f
|
@ -42,6 +42,8 @@
|
||||||
cc.enable = true;
|
cc.enable = true;
|
||||||
common-lisp.enable = true;
|
common-lisp.enable = true;
|
||||||
rust.enable = true;
|
rust.enable = true;
|
||||||
|
# lua.enable = true;
|
||||||
|
# lua.love2d.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
media = {
|
media = {
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
# ./godot.nix
|
# ./godot.nix
|
||||||
# ./haskell.nix
|
# ./haskell.nix
|
||||||
# ./latex.nix
|
# ./latex.nix
|
||||||
# ./love2d.nix
|
./lua.nix
|
||||||
# ./node.nix
|
# ./node.nix
|
||||||
./python.nix
|
./python.nix
|
||||||
./rust.nix
|
./rust.nix
|
||||||
|
|
|
@ -1,15 +0,0 @@
|
||||||
# modules/dev/love2d.nix --- https://love2d.org/
|
|
||||||
#
|
|
||||||
# Love is my favorite little game engine. I use it often for rapid prototyping
|
|
||||||
# when godot is overkill and have the luxury of avoiding JS. I write my Love
|
|
||||||
# games in moonscript to get around the idiosynchrosies of lua.
|
|
||||||
|
|
||||||
{ pkgs, ... }:
|
|
||||||
{
|
|
||||||
my.packages = with pkgs; [
|
|
||||||
love
|
|
||||||
lua
|
|
||||||
luaPackages.moonscript
|
|
||||||
luarocks
|
|
||||||
];
|
|
||||||
}
|
|
29
modules/dev/lua.nix
Normal file
29
modules/dev/lua.nix
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
# modules/dev/lua.nix --- https://www.lua.org/
|
||||||
|
#
|
||||||
|
# I use lua for modding, awesomewm or Love2D for rapid gamedev prototyping (when
|
||||||
|
# godot is overkill and I have the luxury of avoiding JS). I write my Love games
|
||||||
|
# in moonscript to get around lua's idiosynchrosies. That said, I install love2d
|
||||||
|
# on a per-project basis.
|
||||||
|
|
||||||
|
{ config, options, lib, pkgs, ... }:
|
||||||
|
with lib;
|
||||||
|
{
|
||||||
|
options.modules.dev.lua = {
|
||||||
|
enable = mkOption {
|
||||||
|
type = types.bool;
|
||||||
|
default = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf config.modules.dev.lua.enable {
|
||||||
|
my = {
|
||||||
|
packages = with pkgs; [
|
||||||
|
lua
|
||||||
|
luaPackages.moonscript
|
||||||
|
luarocks
|
||||||
|
];
|
||||||
|
|
||||||
|
zsh.rc = ''eval "$(luarocks path --bin)"'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
Loading…
Reference in a new issue