non important commit
This commit is contained in:
parent
f2452cb1bf
commit
f40552b4b7
1 changed files with 55 additions and 56 deletions
|
|
@ -41,72 +41,71 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
if ("ZELLIJ" in $env) {
|
if ("ZELLIJ" in $env) {
|
||||||
zellij
|
zellij
|
||||||
fastfetch
|
exit
|
||||||
exit
|
}
|
||||||
}
|
|
||||||
|
|
||||||
def c [] {
|
def c [] {
|
||||||
clear
|
clear
|
||||||
fastfetch
|
fastfetch
|
||||||
}
|
}
|
||||||
|
|
||||||
def rebuild [message?: string] {
|
def rebuild [message?: string] {
|
||||||
cd /home/benag/.nix-config
|
cd /home/benag/.nix-config
|
||||||
let commit_message = if $message != null {$message} else {"non important commit"}
|
let commit_message = if $message != null {$message} else {"non important commit"}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
git pull
|
git pull
|
||||||
git add .
|
git add .
|
||||||
git commit -m $commit_message
|
git commit -m $commit_message
|
||||||
git push
|
git push
|
||||||
}
|
}
|
||||||
|
|
||||||
sudo nixos-rebuild switch --flake .#benag
|
sudo nixos-rebuild switch --flake .#benag
|
||||||
}
|
}
|
||||||
|
|
||||||
def --env fzf-cd [] {
|
def --env fzf-cd [] {
|
||||||
let dir = (fd -H -t d -L . | fzf --reverse --height 40% --border rounded --preview=("eza --color=always --group-directories-first --icons --long {}") --preview-window=border-left)
|
let dir = (fd -H -t d -L . | fzf --reverse --height 40% --border rounded --preview=("eza --color=always --group-directories-first --icons --long {}") --preview-window=border-left)
|
||||||
|
|
||||||
if $dir != null and $dir != "" {
|
if $dir != null and $dir != "" {
|
||||||
cd $dir
|
cd $dir
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
def --env fzf-nvim [] {
|
def --env fzf-nvim [] {
|
||||||
let file = (fd -H -t f -L . | fzf --reverse --height 40% --border rounded --preview=("bat -p -P --color always {}") --preview-window=border-left)
|
let file = (fd -H -t f -L . | fzf --reverse --height 40% --border rounded --preview=("bat -p -P --color always {}") --preview-window=border-left)
|
||||||
|
|
||||||
if $file != null and $file != "" {
|
if $file != null and $file != "" {
|
||||||
nvim $file
|
nvim $file
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$env.config.keybindings = ($env.config.keybindings | append {
|
$env.config.keybindings = ($env.config.keybindings | append {
|
||||||
name: "fzf-cd"
|
name: "fzf-cd"
|
||||||
modifier: "control"
|
modifier: "control"
|
||||||
keycode: "char_f"
|
keycode: "char_f"
|
||||||
mode: "emacs"
|
mode: "emacs"
|
||||||
event: [
|
event: [
|
||||||
{
|
{
|
||||||
send: "executehostcommand"
|
send: "executehostcommand"
|
||||||
cmd: 'fzf-cd'
|
cmd: 'fzf-cd'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
|
|
||||||
$env.config.keybindings = ($env.config.keybindings | append {
|
$env.config.keybindings = ($env.config.keybindings | append {
|
||||||
name: "fzf-nvim"
|
name: "fzf-nvim"
|
||||||
modifier: "control"
|
modifier: "control"
|
||||||
keycode: "char_e"
|
keycode: "char_e"
|
||||||
mode: "emacs"
|
mode: "emacs"
|
||||||
event: [
|
event: [
|
||||||
{
|
{
|
||||||
send: "executehostcommand"
|
send: "executehostcommand"
|
||||||
cmd: 'fzf-nvim'
|
cmd: 'fzf-nvim'
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue