Skip to content

Commit

Permalink
chore(flake.nix): general cleanup and simplification
Browse files Browse the repository at this point in the history
  • Loading branch information
vhyrro committed May 27, 2024
1 parent e5ca4c4 commit 06fd3da
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
2 changes: 1 addition & 1 deletion nix/checks/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

neorocks-test =
(pkgs.neorocksTest {
src = self;
src = "${self}";
name = "neorg";
version = "scm-1";
neovim = pkgs.neovim-unwrapped;
Expand Down
8 changes: 5 additions & 3 deletions nix/overlays/installed-dependencies.nix
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
{
lib,
pkgs,
runCommand,
lua51Packages,
wget,
self,
}: let
dependencies = builtins.fromJSON (builtins.readFile "${self}/res/deps.json");
in
pkgs.runCommand "install-neorg-dependencies" {
nativeBuildInputs = with pkgs; [lua51Packages.luarocks wget];
runCommand "install-neorg-dependencies" {
nativeBuildInputs = [lua51Packages.luarocks wget];
outputHashAlgo = "sha256";
outputHashMode = "recursive";
outputHash = "sha256-tvMqTgTshVApj3muQyvwj+as/8b7tw1r0BlCTpMlGuU=";
Expand Down
12 changes: 3 additions & 9 deletions nix/overlays/luarc.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,11 @@
lib,
lua51Packages,
mk-luarc,
pkgs,
self,
}: let
luarc = mk-luarc {};
in
luarc
// {
inherit (luarc) runtime;
inherit (luarc.Lua) diagnostics globals;
Lua.workspace = {
inherit (luarc.Lua.workspace) ignoreDir;
library = luarc.Lua.workspace.library ++ ["${installed-dependencies}/luarocks/share/lua/5.1/"];
};
lib.recursiveUpdate luarc
{
Lua.workspace.library = luarc.Lua.workspace.library ++ ["${installed-dependencies}/luarocks/share/lua/5.1/"];
}

0 comments on commit 06fd3da

Please sign in to comment.