From 5a6320cc7872465abc5495b3a1b8568d2c8b6e0e Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Tue, 6 Dec 2022 10:59:21 +0100 Subject: [PATCH] Install windows fonts --- devices/ManuSurface/setup.sh | 3 +++ scripts/PopOS/windows-fonts.sh | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100755 scripts/PopOS/windows-fonts.sh diff --git a/devices/ManuSurface/setup.sh b/devices/ManuSurface/setup.sh index 72924d45..1eb9d0f4 100755 --- a/devices/ManuSurface/setup.sh +++ b/devices/ManuSurface/setup.sh @@ -59,6 +59,9 @@ flatpak install -y flathub ch.threema.threema-web-desktop flatpak install -y flathub app.ytmdesktop.ytmdesktop flatpak install -y flathub com.github.tchx84.Flatseal +# Microsoft Windows Fonts +source "$popOSRoot/windows-fonts.sh" + # Install JetBrains Stuff source "$softwareRoot/jetbrains-toolbox.sh" diff --git a/scripts/PopOS/windows-fonts.sh b/scripts/PopOS/windows-fonts.sh new file mode 100755 index 00000000..48178f4e --- /dev/null +++ b/scripts/PopOS/windows-fonts.sh @@ -0,0 +1,32 @@ +#!/bin/bash +# Elevate script +if [ ! "$UID" -eq 0 ] +then + sudo bash "$BASH_SOURCE" "$USER" +else + apt install -y p7zip-full libgumbo-dev libfuse-dev libssl-dev libcurl4-openssl-dev uuid-dev; + workingDirectory="$(pwd)"; + tempDir="$(mktemp -d)"; + cd $tempDir; + + git clone https://github.com/fangfufu/httpdirfs.git; + pushd httpdirfs; + make; + install -m 755 -D httpdirfs /usr/local/bin/httpdirfs; + popd; + + git clone https://aur.archlinux.org/ttf-ms-win11-auto.git ttf-win11; + cd ttf-win11; + source ./PKGBUILD; + prepare; + package_ttf-ms-win11-auto; + + rm -f /usr/local/bin/httpdirfs; + + cd $tempDir; + wget -O CascadiaCode.zip https://github.com/microsoft/cascadia-code/releases/download/v2111.01/CascadiaCode-2111.01.zip + unzip -d . CascadiaCode.zip; + cp ttf/* /usr/share/fonts/TTF; + + cd $workingDirectory; +fi