mirror of
https://github.com/sadan4/dotfiles.git
synced 2025-06-22 04:07:00 -04:00
direnv
This commit is contained in:
parent
7dd6913f08
commit
0a7223bd6b
6 changed files with 176 additions and 101 deletions
|
@ -21,7 +21,7 @@ in
|
|||
../../../../customPackages
|
||||
];
|
||||
home = {
|
||||
packages = with pkgs; [
|
||||
packages = [
|
||||
# env for clipboard command will be required by their respective environemnts
|
||||
(mkScript {
|
||||
name = "paste";
|
||||
|
@ -34,12 +34,12 @@ in
|
|||
(mkScript {
|
||||
name = "http2ssh";
|
||||
file = ./http2ssh.sh;
|
||||
env = [git];
|
||||
env = [pkgs.git];
|
||||
})
|
||||
(mkScript {
|
||||
name = "git_fetchAll";
|
||||
file = ./git_fetchAll.sh;
|
||||
env = [git];
|
||||
env = [pkgs.git];
|
||||
})
|
||||
(mkScript {
|
||||
name = "install_eslint";
|
||||
|
@ -48,12 +48,17 @@ in
|
|||
(mkScript {
|
||||
name = "math";
|
||||
file = ./math.sh;
|
||||
env = [python3];
|
||||
env = [pkgs.python3];
|
||||
})
|
||||
(mkScript {
|
||||
name = "hashi18n";
|
||||
file = ./hashi18n.sh;
|
||||
})
|
||||
(mkScript {
|
||||
name = "flakeify";
|
||||
file = ./flakeify.sh;
|
||||
deps = [pkgs.direnv];
|
||||
})
|
||||
];
|
||||
file = {
|
||||
scripts = {
|
||||
|
|
7
common/users/homeModules/scripts/flakeify.sh
Normal file
7
common/users/homeModules/scripts/flakeify.sh
Normal file
|
@ -0,0 +1,7 @@
|
|||
if [ ! -e flake.nix ]; then
|
||||
nix flake new -t github:nix-community/nix-direnv .
|
||||
elif [ ! -e .envrc ]; then
|
||||
echo "use flake" > .envrc
|
||||
direnv allow
|
||||
fi
|
||||
${EDITOR:-vim} flake.nix
|
|
@ -27,6 +27,13 @@ in
|
|||
};
|
||||
};
|
||||
programs = {
|
||||
direnv = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
nix-direnv = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
zoxide = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue