Skip to content

Commit

Permalink
Add support for overriding the deb link (for older releases)
Browse files Browse the repository at this point in the history
  • Loading branch information
ceamac committed Oct 17, 2022
1 parent 774b549 commit f5abbca
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion make-vbox-modules-package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ set -e

DISTRO='Debian~bullseye_amd64'

LINK=$(curl https://www.virtualbox.org/wiki/Linux_Downloads | grep ".*${DISTRO}\.deb" | sed -e 's/^.*href="//' -e 's/".*$//')
LINK="$1" # support to override the link to the deb for older builds
[ -z "$LINK" ] && LINK=$(curl https://www.virtualbox.org/wiki/Linux_Downloads | grep ".*${DISTRO}\.deb" | sed -e 's/^.*href="//' -e 's/".*$//')
FILE=${LINK##*/}
VERSION=${FILE#*_}
VERSION=${VERSION%%-*}
Expand Down

0 comments on commit f5abbca

Please sign in to comment.