From 9b49349135a64b26b4ffeee135247e7cb0e01502 Mon Sep 17 00:00:00 2001 From: Andres Montalban Date: Thu, 5 Aug 2021 21:59:06 -0300 Subject: [PATCH] Fix the Dockle package installation Install the latest Dockle package --- src/commands/install.yml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/commands/install.yml b/src/commands/install.yml index b460e1b..fd60619 100644 --- a/src/commands/install.yml +++ b/src/commands/install.yml @@ -4,10 +4,6 @@ steps: - run: name: Install the latest version of Dockle command: | - #VERSION=$( - # curl --silent "https://api.github.com/repos/goodwithtech/dockle/releases/latest" | \ - # grep '"tag_name":' | \ - # sed -E 's/.*"v([^"]+)".*/\1/' \ - #) - VERSION=0.2.4 && curl -L -o dockle.deb https://github.com/goodwithtech/dockle/releases/download/v${VERSION}/dockle_${VERSION}_Linux-64bit.deb - sudo dpkg -i dockle.deb && rm dockle.deb \ No newline at end of file + DOCKLE_PKG=$(curl --silent "https://api.github.com/repos/goodwithtech/dockle/releases/latest" | jq -r '.assets[] | select(.name|test("Linux-64bit.deb$")) | .browser_download_url') + curl -L -o dockle.deb ${DOCKLE_PKG} + sudo dpkg -i dockle.deb && rm dockle.deb