From 3166829e4f4a99f7ffb14f9c9ca95e937a1d47f8 Mon Sep 17 00:00:00 2001 From: Ranomier Date: Wed, 28 Apr 2021 12:38:08 +0200 Subject: [PATCH] Download and extract latest nvim release --- update.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 update.sh diff --git a/update.sh b/update.sh new file mode 100755 index 0000000..c29db78 --- /dev/null +++ b/update.sh @@ -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