From e64d25ef266c5d97ca03f394dc4798bdb33ee896 Mon Sep 17 00:00:00 2001 From: Manuel Thalmann Date: Thu, 16 Mar 2023 20:14:49 +0100 Subject: [PATCH] Mute output of `pushd` and `popd` commands --- profiles/ManuSurface/setup.sh | 4 ++-- profiles/PopOSLive/setup.sh | 4 ++-- scripts/Config/Fonts/MicrosoftFonts/install.sh | 8 ++++---- scripts/Config/GnomeExtensions/install.sh | 8 ++++---- scripts/Config/UserProfile/personal.sh | 8 ++++---- scripts/Config/UserProfile/school.sh | 4 ++-- scripts/Devices/SurfaceBook2/Camera/install.sh | 4 ++-- scripts/Devices/SurfaceBook2/SecureBoot/install.sh | 4 ++-- scripts/Devices/SurfaceBook2/Setup/install.sh | 4 ++-- scripts/OS/PopOS/install.sh | 4 ++-- scripts/Software/Collections/personal.sh | 4 ++-- scripts/Software/Collections/school.sh | 4 ++-- scripts/Software/JetBrains/install-toolbox.sh | 4 ++-- scripts/Software/Oh My Posh/install.sh | 4 ++-- scripts/Software/Python/install.sh | 4 ++-- scripts/Software/Virtual Machine Manager/install.sh | 4 ++-- scripts/Software/Woodpecker CLI/install.sh | 2 +- scripts/Software/git/install.sh | 4 ++-- scripts/Software/tea/install.sh | 4 ++-- 19 files changed, 43 insertions(+), 43 deletions(-) diff --git a/profiles/ManuSurface/setup.sh b/profiles/ManuSurface/setup.sh index 8c418cd1..290e4f20 100755 --- a/profiles/ManuSurface/setup.sh +++ b/profiles/ManuSurface/setup.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; # Set Hostname sudo hostnamectl set-hostname ManuSurface; @@ -13,4 +13,4 @@ source "../../scripts/Config/UserProfile/school.sh"; source "../../scripts/Config/EasyEffects/SurfaceBook2/install.sh"; source "../../scripts/Scripts/postinstall.sh"; -popd; +popd > /dev/null; diff --git a/profiles/PopOSLive/setup.sh b/profiles/PopOSLive/setup.sh index 9bc0512a..f8fb093d 100755 --- a/profiles/PopOSLive/setup.sh +++ b/profiles/PopOSLive/setup.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; # Set Hostname sudo hostnamectl set-hostname ManuPopOSLive; @@ -9,4 +9,4 @@ source "../../scripts/Software/Collections/personal.sh"; source "../../scripts/Config/UserProfile/personal.sh"; source "../../scripts/Scripts/postinstall.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Config/Fonts/MicrosoftFonts/install.sh b/scripts/Config/Fonts/MicrosoftFonts/install.sh index 2ff4ee24..dc5fd96a 100755 --- a/scripts/Config/Fonts/MicrosoftFonts/install.sh +++ b/scripts/Config/Fonts/MicrosoftFonts/install.sh @@ -6,13 +6,13 @@ then else apt install -y p7zip-full libgumbo-dev libexpat1-dev libfuse-dev libssl-dev libcurl4-openssl-dev uuid-dev; tempDir="$(mktemp -d)"; - pushd "$tempDir"; + pushd "$tempDir" > /dev/null; git clone https://github.com/fangfufu/httpdirfs.git; - pushd httpdirfs; + pushd httpdirfs > /dev/null; make; install -m 755 -D httpdirfs /usr/local/bin/httpdirfs; - popd; + popd > /dev/null; git clone https://aur.archlinux.org/ttf-ms-win11-auto.git ttf-win11; cd ttf-win11; @@ -28,5 +28,5 @@ else unzip -d . CascadiaCode.zip; cp ttf/* /usr/share/fonts/TTF; - popd; + popd > /dev/null; fi diff --git a/scripts/Config/GnomeExtensions/install.sh b/scripts/Config/GnomeExtensions/install.sh index 0b0636c6..3ba0ad7c 100755 --- a/scripts/Config/GnomeExtensions/install.sh +++ b/scripts/Config/GnomeExtensions/install.sh @@ -2,13 +2,13 @@ commandName=gnome-shell-extension-installer; extensionLocation=/usr/share/gnome-shell/extensions; contextRoot="$(mktemp -d)"; -pushd "$contextRoot"; +pushd "$contextRoot" > /dev/null; sudo apt install -y jq; wget -O "$commandName" "https://github.com/brunelli/gnome-shell-extension-installer/raw/master/gnome-shell-extension-installer"; sudo install "$commandName" /usr/local/bin; -popd; +popd > /dev/null; rm -rf "$contextRoot"; uuids=(); @@ -16,7 +16,7 @@ for id in 779 4907 1162 do contextRoot="$(mktemp -d)"; unzipLocation="$(mktemp -d)"; - pushd "$contextRoot"; + pushd "$contextRoot" > /dev/null; gnome-shell-extension-installer "$id" --no-install; sudo gnome-shell-extension-installer "$id" --yes; @@ -27,7 +27,7 @@ do sudo chmod -R +r "$extensionLocation/$uuid"; - popd; + popd > /dev/null; rm -rf "$contextRoot"; done diff --git a/scripts/Config/UserProfile/personal.sh b/scripts/Config/UserProfile/personal.sh index d121350b..354f2d8a 100755 --- a/scripts/Config/UserProfile/personal.sh +++ b/scripts/Config/UserProfile/personal.sh @@ -1,6 +1,6 @@ #!/bin/bash dir="${BASH_SOURCE%/*}"; -pushd "$dir"; +pushd "$dir" > /dev/null; scriptRoot="$dir/../.."; softwareRoot="$scriptRoot/Software"; configRoot="$scriptRoot/Config"; @@ -8,13 +8,13 @@ cloudRoot="$configRoot/rclone"; # Sync clouds { - pushd "$dir"; + pushd "$dir" > /dev/null; gnome-terminal --tab --wait -- /bin/bash "../../Config/rclone/InstallSync.sh" nextcloud Nextcloud; # Install fonts source "../../Config/Fonts/NerdFont/install.sh"; source "../../Software/Oh My Posh/install.sh"; - popd; + popd > /dev/null; } & # Microsoft Windows Fonts @@ -25,4 +25,4 @@ source "../../Config/git/setup/install.sh"; # Troll Stuff source "../../Config/git/git-auf-deutsch/install.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Config/UserProfile/school.sh b/scripts/Config/UserProfile/school.sh index 6092e9bc..dd18c672 100755 --- a/scripts/Config/UserProfile/school.sh +++ b/scripts/Config/UserProfile/school.sh @@ -1,6 +1,6 @@ #!/bin/bash # Install JetBrains Stuff -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; source "./personal.sh"; source "../../Software/JetBrains/install-toolbox.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Devices/SurfaceBook2/Camera/install.sh b/scripts/Devices/SurfaceBook2/Camera/install.sh index b77c281d..9521d8f6 100755 --- a/scripts/Devices/SurfaceBook2/Camera/install.sh +++ b/scripts/Devices/SurfaceBook2/Camera/install.sh @@ -1,5 +1,5 @@ contextRoot="$(mktemp -d)"; -pushd "$contextRoot"; +pushd "$contextRoot" > /dev/null; sudo apt install -y \ build-essential meson ninja-build pkg-config libgnutls28-dev openssl \ @@ -14,5 +14,5 @@ meson build -Dpipelines=uvcvideo,vimc,ipu3 -Dipas=vimc,ipu3 -Dprefix=/usr -Dgstr ninja -C build; sudo ninja -C build install; -popd; +popd > /dev/null; rm -rf "$contextRoot"; diff --git a/scripts/Devices/SurfaceBook2/SecureBoot/install.sh b/scripts/Devices/SurfaceBook2/SecureBoot/install.sh index f32efcaa..13e0bf4c 100755 --- a/scripts/Devices/SurfaceBook2/SecureBoot/install.sh +++ b/scripts/Devices/SurfaceBook2/SecureBoot/install.sh @@ -10,7 +10,7 @@ else # Create context directory contextRoot="$(mktemp -d)"; packageName="shim.rpm"; - pushd "$contextRoot"; + pushd "$contextRoot" > /dev/null; # Install Prerequisites apt install -y wget rpm2cpio efitools; @@ -104,6 +104,6 @@ else mokutil --import "$keyDir/MOK.der"; # Remove context directory - popd; + popd > /dev/null; rm -rf "$contextRoot"; fi diff --git a/scripts/Devices/SurfaceBook2/Setup/install.sh b/scripts/Devices/SurfaceBook2/Setup/install.sh index 5b174ba8..220de3da 100755 --- a/scripts/Devices/SurfaceBook2/Setup/install.sh +++ b/scripts/Devices/SurfaceBook2/Setup/install.sh @@ -1,8 +1,8 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; # Install surface-linux source "../../Surface/LinuxSurface/install.sh"; source "../../SurfaceBook2/Camera/install.sh"; # source "../../SurfaceBook2/SecureBoot/install.sh"; -popd; +popd > /dev/null; diff --git a/scripts/OS/PopOS/install.sh b/scripts/OS/PopOS/install.sh index 35505b59..aeb326e3 100755 --- a/scripts/OS/PopOS/install.sh +++ b/scripts/OS/PopOS/install.sh @@ -1,4 +1,4 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; source "../../Config/GnomeExtensions/install.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Software/Collections/personal.sh b/scripts/Software/Collections/personal.sh index 1ceb8df9..486c4639 100755 --- a/scripts/Software/Collections/personal.sh +++ b/scripts/Software/Collections/personal.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; scriptRoot="$dir/../.."; utilRoot="$scriptRoot/Scripts"; deviceRoot="$scriptRoot/Devices"; @@ -39,4 +39,4 @@ flatpak install -y flathub com.github.wwmm.easyeffects; flatpak install -y flathub ch.threema.threema-web-desktop; flatpak install -y flathub app.ytmdesktop.ytmdesktop; flatpak install -y flathub com.github.tchx84.Flatseal; -popd; +popd > /dev/null; diff --git a/scripts/Software/Collections/school.sh b/scripts/Software/Collections/school.sh index 4c22310a..625f9d1c 100755 --- a/scripts/Software/Collections/school.sh +++ b/scripts/Software/Collections/school.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; source "./personal.sh"; source "../Java/install.sh"; @@ -8,4 +8,4 @@ source "../cloudflared/install.sh"; # Install other flatpaks flatpak install -y flathub com.github.xournalpp.xournalpp; flatpak install -y flathub com.github.flxzt.rnote; -popd; +popd > /dev/null; diff --git a/scripts/Software/JetBrains/install-toolbox.sh b/scripts/Software/JetBrains/install-toolbox.sh index 4c2d1ac2..76752537 100755 --- a/scripts/Software/JetBrains/install-toolbox.sh +++ b/scripts/Software/JetBrains/install-toolbox.sh @@ -5,12 +5,12 @@ then sudo bash "$BASH_SOURCE"; else contextRoot="$(mktemp -d)"; - pushd "$contextRoot"; + pushd "$contextRoot" > /dev/null; curl -fsSL https://raw.githubusercontent.com/nagygergo/jetbrains-toolbox-install/1.1/jetbrains-toolbox.sh \ | bash; - popd; + popd > /dev/null; rm -rf "$contextRoot"; { diff --git a/scripts/Software/Oh My Posh/install.sh b/scripts/Software/Oh My Posh/install.sh index 6a21bf10..81af386f 100755 --- a/scripts/Software/Oh My Posh/install.sh +++ b/scripts/Software/Oh My Posh/install.sh @@ -6,12 +6,12 @@ then else bin=oh-my-posh; contextRoot="$(mktemp -d)"; - pushd "$contextRoot"; + pushd "$contextRoot" > /dev/null; wget https://github.com/JanDeDobbeleer/oh-my-posh/releases/latest/download/posh-linux-amd64 -O "$bin"; install "$bin" /usr/local/bin; - popd; + popd > /dev/null; rm -rf "$contextRoot"; homeDir="$(sudo -u "$1" bash -c 'realpath ~')"; diff --git a/scripts/Software/Python/install.sh b/scripts/Software/Python/install.sh index ea35a9d2..b73eed33 100755 --- a/scripts/Software/Python/install.sh +++ b/scripts/Software/Python/install.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; source "./setup.sh"; source "./pyenv.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Software/Virtual Machine Manager/install.sh b/scripts/Software/Virtual Machine Manager/install.sh index 72e79c3f..7afefc2b 100755 --- a/scripts/Software/Virtual Machine Manager/install.sh +++ b/scripts/Software/Virtual Machine Manager/install.sh @@ -1,11 +1,11 @@ #!/bin/bash contextRoot="$(mktemp -d)"; -pushd "$contextRoot"; +pushd "$contextRoot" > /dev/null; sudo apt install -y swtpm swtpm-tools lxc libvirt-daemon-driver-lxc libvirt-daemon-system virt-manager; sudo apt install -y python3 python-is-python3 python3-guestfs python3-passlib; git clone https://github.com/virt-manager/virt-bootstrap; cd virt-bootstrap; sudo python setup.py install; -popd; +popd > /dev/null; rm -rf "$contextRoot"; diff --git a/scripts/Software/Woodpecker CLI/install.sh b/scripts/Software/Woodpecker CLI/install.sh index 297f7e6a..ea5217a8 100755 --- a/scripts/Software/Woodpecker CLI/install.sh +++ b/scripts/Software/Woodpecker CLI/install.sh @@ -18,6 +18,6 @@ else tar -xvzf woodpecker-cli.tar.gz; install woodpecker-cli /usr/local/bin; - popd; + popd > /dev/null; rm -rf "$contextRoot"; fi diff --git a/scripts/Software/git/install.sh b/scripts/Software/git/install.sh index 99136531..c8ee4dc5 100755 --- a/scripts/Software/git/install.sh +++ b/scripts/Software/git/install.sh @@ -1,5 +1,5 @@ #!/bin/bash -pushd "${BASH_SOURCE%/*}"; +pushd "${BASH_SOURCE%/*}" > /dev/null; source "./flow.sh"; source "./lfs.sh"; -popd; +popd > /dev/null; diff --git a/scripts/Software/tea/install.sh b/scripts/Software/tea/install.sh index 7829435c..55b6bd45 100755 --- a/scripts/Software/tea/install.sh +++ b/scripts/Software/tea/install.sh @@ -5,11 +5,11 @@ then sudo bash "$BASH_SOURCE"; else contextRoot="$(mktemp -d)"; - pushd "$contextRoot"; + pushd "$contextRoot" > /dev/null; wget https://dl.gitea.io/tea/0.9.0/tea-0.9.0-linux-amd64 -O tea; install tea /usr/local/bin; - popd; + popd > /dev/null; rm -rf "$contextRoot"; fi