Skip to content

Commit

Permalink
Add automated install-update script for Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
immanuelfodor authored Jul 1, 2019
1 parent c1764d8 commit e581848
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions scripts/install_update_linux.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

GITHUB_LATEST_VERSION=$(curl -L -s -H 'Accept: application/json' https://github.com/jesseduffield/lazydocker/releases/latest | sed -e 's/.*"tag_name":"\([^"]*\)".*/\1/')
GITHUB_FILE="lazydocker_${GITHUB_LATEST_VERSION//v/}_$(uname -s)_$(uname -m).tar.gz"
GITHUB_URL="https://github.com/jesseduffield/lazydocker/releases/download/${GITHUB_LATEST_VERSION}/${GITHUB_FILE}"

wget -O lazydocker.tar.gz $GITHUB_URL
tar xzvf lazydocker.tar.gz lazydocker
sudo mv -f lazydocker /usr/local/bin/
rm lazydocker.tar.gz

0 comments on commit e581848

Please sign in to comment.