Switch to standard direnv module

This commit is contained in:
Kiana Sheibani 2024-01-13 13:56:07 -05:00
parent 1f213d463c
commit a648517bd9
2 changed files with 5 additions and 15 deletions

View file

@ -1,8 +1,5 @@
{ config, pkgs, nixpkgs, ... }: { config, pkgs, ... }:
let let
# nix-direnv with flake support
nix-direnv-with-flakes = pkgs.nix-direnv.override { enableFlakes = true; };
emacs29 = pkgs.emacs29.override { emacs29 = pkgs.emacs29.override {
withPgtk = true; withPgtk = true;
withWebP = true; withWebP = true;
@ -30,9 +27,6 @@ in {
(aspellWithDicts (ps: with ps; [ en en-computers en-science ])) (aspellWithDicts (ps: with ps; [ en en-computers en-science ]))
gcc gcc
direnv
nix-direnv-with-flakes
]; ];
programs.fish.enable = true; programs.fish.enable = true;
@ -46,12 +40,12 @@ in {
services.emacs.enable = true; services.emacs.enable = true;
services.emacs.package = emacs29; services.emacs.package = emacs29;
# direnv setup programs.direnv.enable = true;
programs.direnv.nix-direnv.enable = true;
programs.direnv.silent = true;
nix.extraOptions = '' nix.extraOptions = ''
keep-derivations = true keep-derivations = true
keep-outputs = true keep-outputs = true
''; '';
environment.pathsToLink = [ "/share/nix-direnv" ];
} }

View file

@ -7,15 +7,11 @@
programs.fish.enable = true; programs.fish.enable = true;
# Hook nix-direnv to shell # rlwrap config
programs.fish.shellInit = '' programs.fish.shellInit = ''
set -xg DIRENV_LOG_FORMAT ""
direnv hook fish | source
set -xg RLWRAP_HOME $XDG_DATA_HOME/rlwrap set -xg RLWRAP_HOME $XDG_DATA_HOME/rlwrap
''; '';
home.packages = [ pkgs.rlwrap ]; home.packages = [ pkgs.rlwrap ];
} }