From 2ecf6b86a0c823b3ad818004a016eb3b8a043a5a Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Sun, 17 Sep 2023 20:09:04 +0000 Subject: [PATCH] fi --- src/wine/devcontainer-feature.json | 2 +- src/wine/install.sh | 19 +++++++++---------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/src/wine/devcontainer-feature.json b/src/wine/devcontainer-feature.json index 07ecb92..1645ab6 100644 --- a/src/wine/devcontainer-feature.json +++ b/src/wine/devcontainer-feature.json @@ -6,7 +6,7 @@ "options": { "version": { "type": "string", - "default": "8.15" + "default": "latest" } }, "installsAfter": [ diff --git a/src/wine/install.sh b/src/wine/install.sh index c06425f..49dd128 100644 --- a/src/wine/install.sh +++ b/src/wine/install.sh @@ -1,11 +1,7 @@ #!/bin/sh set -e -WINEVERSION=$WINEVERSION -WINEHOME="/home/root" -WINEPREFIX="$WINEHOME/.wine32" -WINEARCH="win32" -WINEDEBUG=-all +WINEVERSION="${VERSION:-"latest"}" install_debian() { export DEBIAN_FRONTEND=noninteractive @@ -21,11 +17,14 @@ install_debian() { wget https://dl.winehq.org/wine-builds/winehq.key -O - | apt-key add - echo "deb https://dl.winehq.org/wine-builds/debian $VERSION_CODENAME main" >/etc/apt/sources.list.d/winehq.list - { - echo "Package: *wine* *wine*:i386" - echo "Pin: version $WINEVERSION~$VERSION_CODENAME" - echo "Pin-Priority: 1001" - } >/etc/apt/preferences.d/winehq.pref + + if [ "${WINEVERSION}" != "latest" ]; then + { + echo "Package: *wine* *wine*:i386" + echo "Pin: version $WINEVERSION~$VERSION_CODENAME" + echo "Pin-Priority: 1001" + } >/etc/apt/preferences.d/winehq.pref + fi apt-get update apt-get install -y --no-install-recommends winehq-stable