From 91788579dd29d98d131e23d6d8670991115f8a52 Mon Sep 17 00:00:00 2001 From: Daniel Langbein Date: Fri, 10 Sep 2021 15:59:33 +0200 Subject: [PATCH] refactor and fix --- pkg/de-p1st-gnupg/interactive-shell.holoscript | 1 + pkg/de-p1st-gpu-amdgpu/mkinitcpio.conf.holoscript | 1 + pkg/de-p1st-grub/grub.holoscript | 1 + pkg/de-p1st-makepkg/makepkg.conf.holoscript | 1 + pkg/de-p1st-nano/nanorc.holoscript | 1 + pkg/de-p1st-pacman/PKGBUILD | 2 +- pkg/de-p1st-pacman/pacman.conf.holoscript | 8 +++++++- pkg/de-p1st-screen/screenrc.holoscript | 1 + pkg/de-p1st-sddm-theme-nordic/Main.qml.holoscript | 1 + pkg/de-p1st-smartcard/opensc.conf.holoscript | 1 + pkg/de-p1st-xfce4-hidpi/thunar.xml.holoscript | 1 + pkg/de-p1st-zoom/Zoom.desktop.holoscript | 1 + 12 files changed, 18 insertions(+), 2 deletions(-) diff --git a/pkg/de-p1st-gnupg/interactive-shell.holoscript b/pkg/de-p1st-gnupg/interactive-shell.holoscript index 9a41395..3068052 100644 --- a/pkg/de-p1st-gnupg/interactive-shell.holoscript +++ b/pkg/de-p1st-gnupg/interactive-shell.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e cat echo ' diff --git a/pkg/de-p1st-gpu-amdgpu/mkinitcpio.conf.holoscript b/pkg/de-p1st-gpu-amdgpu/mkinitcpio.conf.holoscript index b77828c..51d564f 100644 --- a/pkg/de-p1st-gpu-amdgpu/mkinitcpio.conf.holoscript +++ b/pkg/de-p1st-gpu-amdgpu/mkinitcpio.conf.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e # add amdgpu to MODULES array sed 's|^MODULES=(|MODULES=(amdgpu |' diff --git a/pkg/de-p1st-grub/grub.holoscript b/pkg/de-p1st-grub/grub.holoscript index 717dbf7..74ec1d6 100644 --- a/pkg/de-p1st-grub/grub.holoscript +++ b/pkg/de-p1st-grub/grub.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e # 1) and 2) remember last selected entry; 3) disable submenu sed ' diff --git a/pkg/de-p1st-makepkg/makepkg.conf.holoscript b/pkg/de-p1st-makepkg/makepkg.conf.holoscript index e6d70ac..3d26743 100644 --- a/pkg/de-p1st-makepkg/makepkg.conf.holoscript +++ b/pkg/de-p1st-makepkg/makepkg.conf.holoscript @@ -1,5 +1,6 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e sed 's|^#PACKAGER=.*$|PACKAGER="Daniel Langbein "|' diff --git a/pkg/de-p1st-nano/nanorc.holoscript b/pkg/de-p1st-nano/nanorc.holoscript index 26b2f98..a9a3090 100644 --- a/pkg/de-p1st-nano/nanorc.holoscript +++ b/pkg/de-p1st-nano/nanorc.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e cat # syntax highlighting diff --git a/pkg/de-p1st-pacman/PKGBUILD b/pkg/de-p1st-pacman/PKGBUILD index 473483d..4e28f23 100644 --- a/pkg/de-p1st-pacman/PKGBUILD +++ b/pkg/de-p1st-pacman/PKGBUILD @@ -3,7 +3,7 @@ _pkgname=pacman _reponame=arch pkgname="de-p1st-$_pkgname" pkgver=0.2.2 -pkgrel=1 +pkgrel=2 pkgdesc="pacman with configuration" arch=('any') url="https://codeberg.org/privacy1st/${_reponame}" diff --git a/pkg/de-p1st-pacman/pacman.conf.holoscript b/pkg/de-p1st-pacman/pacman.conf.holoscript index 1b143ee..3d75ab7 100644 --- a/pkg/de-p1st-pacman/pacman.conf.holoscript +++ b/pkg/de-p1st-pacman/pacman.conf.holoscript @@ -1,9 +1,15 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e + +# save stdin (content of /etc/mkinitcpio.conf) in variable +stdin="$(cat)" # Enable parallel downloads -sed 's|^#ParallelDownloads\s*=.*$|ParallelDownloads = 4|' +echo "$stdin" | sed 's|^#ParallelDownloads\s*=.*$|ParallelDownloads = 4|' + +printf '\n' # Assert multilib is not enabled ! echo "$stdin" | grep --quiet '^\[multilib\].*$' diff --git a/pkg/de-p1st-screen/screenrc.holoscript b/pkg/de-p1st-screen/screenrc.holoscript index a42691b..3fa8695 100644 --- a/pkg/de-p1st-screen/screenrc.holoscript +++ b/pkg/de-p1st-screen/screenrc.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e cat echo ' diff --git a/pkg/de-p1st-sddm-theme-nordic/Main.qml.holoscript b/pkg/de-p1st-sddm-theme-nordic/Main.qml.holoscript index 2215da5..06906b5 100644 --- a/pkg/de-p1st-sddm-theme-nordic/Main.qml.holoscript +++ b/pkg/de-p1st-sddm-theme-nordic/Main.qml.holoscript @@ -1,5 +1,6 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e sed 's|Battery {}|//Battery {}|' diff --git a/pkg/de-p1st-smartcard/opensc.conf.holoscript b/pkg/de-p1st-smartcard/opensc.conf.holoscript index 31e4c4e..8fbcc19 100644 --- a/pkg/de-p1st-smartcard/opensc.conf.holoscript +++ b/pkg/de-p1st-smartcard/opensc.conf.holoscript @@ -1,5 +1,6 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e cat echo 'enable_pinpad = false' diff --git a/pkg/de-p1st-xfce4-hidpi/thunar.xml.holoscript b/pkg/de-p1st-xfce4-hidpi/thunar.xml.holoscript index 3ed447a..6f8a49b 100644 --- a/pkg/de-p1st-xfce4-hidpi/thunar.xml.holoscript +++ b/pkg/de-p1st-xfce4-hidpi/thunar.xml.holoscript @@ -1,6 +1,7 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e # Decrease size sed ' diff --git a/pkg/de-p1st-zoom/Zoom.desktop.holoscript b/pkg/de-p1st-zoom/Zoom.desktop.holoscript index ecb540c..86d152f 100644 --- a/pkg/de-p1st-zoom/Zoom.desktop.holoscript +++ b/pkg/de-p1st-zoom/Zoom.desktop.holoscript @@ -1,5 +1,6 @@ #!/bin/sh # stdin: default config # stdout: modified config +set -e echo "NoDisplay=true"