feat: add, setup asdf, prepare plugins

This commit is contained in:
hophacker 2021-12-25 16:23:07 +08:00
parent 7e233ae717
commit e4cc2792be
3 changed files with 15 additions and 0 deletions

View File

@ -40,6 +40,7 @@ task install: %i[submodule_init submodules] do
Rake::Task['install_tools'].execute Rake::Task['install_tools'].execute
Rake::Task['install_prezto'].execute Rake::Task['install_prezto'].execute
Rake::Task['install_spacevim'].execute Rake::Task['install_spacevim'].execute
Rake::Task['install_asdf'].execute
install_fonts install_fonts
@ -69,6 +70,17 @@ task :update_spacevim do
) )
end end
desc 'install asdf'
task :install_asdf do
run 'git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.8.1'
install_files(Dir.glob('asdf/*')) if want_to_install?('tool version manager asdf')
run %(
. $HOME/.asdf/asdf.sh
asdf plugin-add kubetail https://github.com/janpieper/asdf-kubetail.git
asdf install
)
end
desc 'Install tools which are necessary for developers' desc 'Install tools which are necessary for developers'
task :install_tools do task :install_tools do
if macos? if macos?

1
asdf/tool-versions Normal file
View File

@ -0,0 +1 @@
kubetail 1.6.13

View File

@ -26,3 +26,5 @@ export NVM_DIR="$HOME/.nvm"
# Add RVM to PATH for scripting. Make sure this is the last PATH variable change. # Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
export PATH="$PATH:$HOME/.rvm/bin" export PATH="$PATH:$HOME/.rvm/bin"
[ -s $HOME/.asdf/asdf.sh ] && . $HOME/.asdf/asdf.sh