mirror of
https://git.sr.ht/~rouven/nixos-config
synced 2025-04-25 16:08:30 +02:00
zsh: attempt to fix fzf-tab
This commit is contained in:
parent
2297f6506d
commit
1474c79742
2 changed files with 17 additions and 6 deletions
|
@ -3,7 +3,6 @@
|
|||
programs.command-not-found.enable = false;
|
||||
programs.nix-index-database.comma.enable = true;
|
||||
environment.systemPackages = with pkgs; [
|
||||
# fzf
|
||||
bat
|
||||
eza
|
||||
duf
|
||||
|
@ -12,6 +11,7 @@
|
|||
iperf
|
||||
];
|
||||
users.defaultUserShell = pkgs.zsh;
|
||||
programs.fzf.enable = true;
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
shellAliases = {
|
||||
|
@ -49,7 +49,7 @@
|
|||
|
||||
|
||||
function svpn() {
|
||||
unit=$(systemctl list-unit-files | grep "openconnect\|wg-quick\|wireguard\|openvpn\|openfortivpn" | cut -d "." -f1 | fzf --preview 'systemctl status {}')
|
||||
unit=$(systemctl list-unit-files | grep "openconnect\|wg-quick\|wireguard\|openvpn\|openfortivpn" | cut -d "." -f1 | ${pkgs.fzf}/bin/fzf --preview 'systemctl status {}')
|
||||
if [ $(systemctl is-active $unit) = "inactive" ]; then
|
||||
systemctl start $unit
|
||||
else
|
||||
|
@ -85,10 +85,10 @@
|
|||
'';
|
||||
promptInit =
|
||||
''
|
||||
if [[ "$(hostname)" == "thinkpad" ]]
|
||||
then
|
||||
cat ${../images/cat.sixel}
|
||||
fi
|
||||
# if [[ "$(hostname)" == "thinkpad" ]]
|
||||
# then
|
||||
# cat ${../images/cat.sixel}
|
||||
# fi
|
||||
eval "$(${pkgs.mcfly}/bin/mcfly init zsh)"
|
||||
eval "$(${pkgs.zoxide}/bin/zoxide init zsh)"
|
||||
'';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue