bugfixing
This commit is contained in:
parent
3082796a0e
commit
8210201ae7
1 changed files with 21 additions and 35 deletions
|
@ -171,9 +171,11 @@ end
|
||||||
# │ FUNCTION: check fisher plugin dependencies │
|
# │ FUNCTION: check fisher plugin dependencies │
|
||||||
# ╰────────────────────────────────────────────╯
|
# ╰────────────────────────────────────────────╯
|
||||||
function dep_fisher
|
function dep_fisher
|
||||||
# Define dependencies for the plugins used by fisher
|
# ─< Define dependencies for the plugins used by fisher >───────────────────────────────────
|
||||||
set dependencies "fzf"
|
begin
|
||||||
# Check and install dependencies
|
set dependencies "fzf" "rg"
|
||||||
|
alias rg="ripgrep"
|
||||||
|
# ─< Check and install dependencies >───────────────────────────────────────────────────────
|
||||||
for dep in $dependencies
|
for dep in $dependencies
|
||||||
if not command -v $dep >/dev/null 2>&1
|
if not command -v $dep >/dev/null 2>&1
|
||||||
echo "Dependency $dep is not installed. Installing..."
|
echo "Dependency $dep is not installed. Installing..."
|
||||||
|
@ -186,32 +188,16 @@ function dep_fisher
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
# ╭───────────────────────────────────────────────────────╮
|
# ╭───────────────────────────────────────────────────────╮
|
||||||
# │ FUNCTION: check for fisher and install if not present │
|
# │ FUNCTION: check for fisher and install if not present │
|
||||||
# ╰───────────────────────────────────────────────────────╯
|
# ╰───────────────────────────────────────────────────────╯
|
||||||
|
|
||||||
function inst_fisher
|
begin
|
||||||
fisher install jorgebucaran/fisher
|
function check_fishr
|
||||||
end
|
if test ! -e $HOME/.config/fish/functions/fisher.fish && test ! -e $HOME/.config/fish/.fishr.init
|
||||||
|
echo "you did it!!"> $HOME/.config/fish/.fishr.init && curl -sL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish | source && fisher install jorgebucaran/fisher
|
||||||
function check_fisher
|
|
||||||
set check_fisher = "false"
|
|
||||||
while $check_fisher != "true"
|
|
||||||
echo "check_fisher == flase"
|
|
||||||
sleep 1
|
|
||||||
# if $check_fisher = "true"
|
|
||||||
fisher update >/dev/null 2>&1
|
|
||||||
switch $status
|
|
||||||
case 0
|
|
||||||
set -U check_fisher "true"
|
|
||||||
echo "check_fisher == true"
|
|
||||||
sleep 1
|
|
||||||
case '*'
|
|
||||||
if test ! -e $HOME/.config/fish/functions/fisher.fish
|
|
||||||
curl -sL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish >> $HOME/.config/fish/functions/fisher.fish
|
|
||||||
inst_fisher
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
@ -219,4 +205,4 @@ end
|
||||||
# ────────────────────────────────────< setup some stuff >────────────────────────────────────
|
# ────────────────────────────────────< setup some stuff >────────────────────────────────────
|
||||||
upin
|
upin
|
||||||
dep_fisher
|
dep_fisher
|
||||||
check_fisher
|
check_fishr
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue