Skip to content

Commit

Permalink
Upgrade repos to 39
Browse files Browse the repository at this point in the history
  • Loading branch information
crramirez committed Nov 21, 2023
1 parent 4c6f323 commit f8d8bc4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 14 deletions.
15 changes: 7 additions & 8 deletions create-targz.sh
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ function build() {
cp "${origin_dir}"/linux_files/start-systemd.sh "${TMPDIR}"/dist/usr/local/bin/start-systemd
chmod +x "${TMPDIR}"/dist/usr/local/bin/start-systemd

cp "${origin_dir}"/linux_files/wsl2-xwayland.service "${TMPDIR}"/dist/etc/systemd/system/wsl2-xwayland.service
cp "${origin_dir}"/linux_files/wsl2-xwayland.socket "${TMPDIR}"/dist/etc/systemd/system/wsl2-xwayland.socket
ln -sf ../wsl2-xwayland.socket "${TMPDIR}"/dist/etc/systemd/system/sockets.target.wants/
cp "${origin_dir}"/linux_files/wsl2-xwayland.service "${TMPDIR}"/dist/etc/systemd/system/wsl2-xwayland.service
cp "${origin_dir}"/linux_files/wsl2-xwayland.socket "${TMPDIR}"/dist/etc/systemd/system/wsl2-xwayland.socket
ln -sf ../wsl2-xwayland.socket "${TMPDIR}"/dist/etc/systemd/system/sockets.target.wants/

cp "${origin_dir}"/linux_files/systemctl3.py "${TMPDIR}"/dist/usr/local/bin/wslsystemctl
chmod +x "${TMPDIR}"/dist/usr/local/bin/wslsystemctl
Expand Down Expand Up @@ -121,7 +121,7 @@ EOF

echo "##[section] 'Setup Whitewater Foundry repo"
systemd-nspawn -q --resolv-conf="replace-host" -D "${TMPDIR}"/dist --pipe /bin/bash <<EOF
curl -s https://packagecloud.io/install/repositories/whitewaterfoundry/fedoraremix/script.rpm.sh | env os=fedora dist=38 bash
curl -s https://packagecloud.io/install/repositories/whitewaterfoundry/fedoraremix/script.rpm.sh | env os=fedora dist=${version_id} bash
dnf update --refresh
EOF

Expand Down Expand Up @@ -149,10 +149,9 @@ EOF

echo "##[section] 'Setup WSLU"
systemd-nspawn -q --resolv-conf="replace-host" -D "${TMPDIR}"/dist --pipe /bin/bash <<EOF
#(
#source /etc/os-release && dnf -y copr enable wslutilities/wslu "\${ID_LIKE}-38-${arch}"
#)
#sudo sed -i "s/\$releasever/38/g" /etc/yum.repos.d/_copr\:copr.fedorainfracloud.org\:wslutilities\:wslu.repo
(
source /etc/os-release && dnf -y copr enable wslutilities/wslu "\${ID_LIKE}-${version_id}-${arch}"
)
dnf -y install wslu
EOF

Expand Down
7 changes: 1 addition & 6 deletions linux_files/upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,6 @@ declare -a target_version=('37' '38' '39')
declare -i length=${#mesa_version[@]}

for (( i = 0; i < length; i++ )); do
if [[ ${VERSION_ID} -eq '39' ]]; then
VERSION_ID='38'
fi

if [[ ${VERSION_ID} -eq ${target_version[i]} && $( sudo dnf info --installed mesa-libGL | grep -c "${mesa_version[i]}" ) == 0 ]]; then

sudo dnf versionlock delete mesa-dri-drivers mesa-libGL mesa-filesystem mesa-libglapi mesa-va-drivers mesa-vdpau-drivers mesa-libEGL mesa-libgbm mesa-libxatracker mesa-vulkan-drivers
Expand All @@ -78,10 +74,9 @@ if [[ $(id | grep -c video) == 0 ]]; then
sudo /usr/sbin/usermod -aG video "$(whoami)"
fi

if [[ $(sudo dnf -y copr list | grep -c "trustywolf/wslu") == 1 ]]; then
if [[ $(sudo dnf -y copr list | grep -c "wslutilities/wslu") == 0 ]]; then
(
source /etc/os-release
sudo dnf -y copr remove trustywolf/wslu "${ID_LIKE}"-"${VERSION_ID}"-"$(uname -m)"
sudo dnf -y copr enable wslutilities/wslu "${ID_LIKE}"-"${VERSION_ID}"-"$(uname -m)"
)
fi
Expand Down

0 comments on commit f8d8bc4

Please sign in to comment.