🚀 perf(fish): added min and max depth for the repos function

This commit is contained in:
Sergio Laín 2023-12-12 11:36:13 +01:00
parent 4adea9334e
commit 0fa96db0da
No known key found for this signature in database
GPG key ID: 14C9B8080681777B

View file

@ -1,6 +1,6 @@
function repos --description 'Open Git directories in ~/Repos with fzf in a new Kitty tab'
set gfetch "gfetch -d churn contributors --no-color-palette --no-title"
set selected_dir (find ~/Repos -type d -exec test -e '{}/.git' ';' -print -prune | fzf --preview "$gfetch {} && eza --long --header --icons --all --color=always --group-directories-first --hyperlink {}")
set selected_dir (find ~/Repos -mindepth 2 -maxdepth 2 -type d -exec test -e '{}/.git' ';' -print -prune | fzf --preview "$gfetch {} && eza --long --header --icons --all --color=always --group-directories-first --hyperlink {}")
if test -n "$selected_dir"
set tab_title (basename "$selected_dir")