mirror of
https://github.com/LnL7/nix-darwin.git
synced 2025-03-28 02:37:09 +00:00
lnl: load :u packages in current instead of a subshell
This commit is contained in:
parent
e274978a65
commit
da52dc006c
1 changed files with 12 additions and 4 deletions
|
@ -168,6 +168,8 @@
|
|||
# Dotfiles.
|
||||
# programs.vim.package = mkForce pkgs.lnl.vim;
|
||||
|
||||
programs.bash.enableCompletion = true;
|
||||
|
||||
programs.zsh.enable = true;
|
||||
programs.zsh.enableBashCompletion = true;
|
||||
programs.zsh.enableFzfCompletion = true;
|
||||
|
@ -201,10 +203,6 @@
|
|||
nix repl ''${@:-<dotpkgs>}
|
||||
}
|
||||
|
||||
:u() {
|
||||
nix run -f '<dotpkgs>' "$1" "$@"
|
||||
}
|
||||
|
||||
:d() {
|
||||
eval "$(direnv hook zsh)"
|
||||
}
|
||||
|
@ -213,6 +211,16 @@
|
|||
direnv reload
|
||||
}
|
||||
|
||||
:u() {
|
||||
local exports
|
||||
|
||||
exports=$(direnv apply_dump <(nix-shell -E "with import <dotpkgs> {}; mkShell { buildInputs = [ $* ]; }" --run 'direnv dump'))
|
||||
eval "$exports"
|
||||
|
||||
name+="''${name:+ }$*"
|
||||
typeset -U PATH
|
||||
}
|
||||
|
||||
xi() {
|
||||
curl -F 'f:1=<-' ix.io
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue