Add branch install for dev

This commit is contained in:
Ilan Cosman 2020-05-21 14:32:03 -07:00
parent eafe0bf3b4
commit 743becdafe
2 changed files with 18 additions and 12 deletions

View File

@ -1,11 +0,0 @@
function bench -a command times
set -l thingToRun
for i in (seq $times)
set -a thingToRun $command
end
eval (string join ';' $thingToRun) >>'/dev/null'
math $CMD_DURATION/$times
end

View File

@ -1,4 +1,21 @@
function local_install -a localRepo
function tide_dev_install
argparse 'b/branch' 'l/local' -- $argv
if set -q _flag_branch
curl -s "https://raw.githubusercontent.com/IlanCosman/tide/$argv/install.fish" | source; and tide_install $argv
return $status
end
if set -q _flag_local
_local_install $argv
return $status
end
printf '%s' 'Please indicate local/branch'
return 1
end
function _local_install -a localRepo
if source "$localRepo/install.fish"
cp -r "$localRepo/conf.d" $__fish_config_dir
cp -r "$localRepo/functions" $__fish_config_dir