Download and extract latest nvim release
This commit is contained in:
commit
3166829e4f
1 changed files with 24 additions and 0 deletions
24
update.sh
Executable file
24
update.sh
Executable file
|
@ -0,0 +1,24 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
#set -eu -o pipefail
|
||||
|
||||
URLS="$(\
|
||||
curl -s https://api.github.com/repos/neovim/neovim/releases/latest |
|
||||
grep -o 'https://.*linux64\.tar\.gz')\n"
|
||||
FILENAMES="$(printf "$URLS" | xargs basename)"
|
||||
|
||||
|
||||
printf ">> Found the following files:\n"
|
||||
printf "$URLS"
|
||||
printf "\n"
|
||||
|
||||
printf ">> Downloading files:\n"
|
||||
printf "$URLS" | xargs curl -LJO --progress-bar
|
||||
printf "\n"
|
||||
|
||||
printf ">> Extracting files... "
|
||||
printf "$FILENAMES" | xargs tar -xf
|
||||
printf "done\n\n"
|
||||
|
||||
printf ">> Removing files:\n"
|
||||
printf "$FILENAMES" | xargs rm -v
|
Loading…
Add table
Reference in a new issue