diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..7381045 --- /dev/null +++ b/install.sh @@ -0,0 +1,34 @@ +#!/bin/bash +pkgName=plasma-nm; +pkgDir="$pkgName/trunk"; +patchName="sso.patch"; +workingDir="$(pwd)"; +tempDir="$(mktemp -d)"; + +yay -G -f "$pkgName"; +git clone https://invent.kde.org/plasma/plasma-nm.git "$tempDir"; +cd "$tempDir"; +git format-patch -1 c1fff723f2e1ee117a10809562c9142103910a70 --stdout > "$workingDir/$pkgDir/1-$patchName"; +git format-patch -1 6ef64be8645ac32fc0b42df2cee5d9ff3b57e485 --stdout > "$workingDir/$pkgDir/2-$patchName"; +cd "$workingDir"; +rm -rf "$tempDir"; + +cd "$pkgDir"; + +sed -i \ + -e "s/^source=(/\01-$patchName 2-$patchName /" \ + -e "s/^sha256sums=(/\0'SKIP' 'SKIP'\n/" \ + -e '/^build() {$/,/^}$/{' \ + -e '/{$/{' \ + -e 'a cd "$pkgname-$pkgver"' \ + -e "a cat '../1-$patchName' | patch --strip 1 --forward --merge" \ + -e "a cat '../2-$patchName' | patch --strip 1 --forward --merge" \ + -e "a cd .." \ + -e '}' \ + -e '}' \ + PKGBUILD; + +makepkg -si --skippgpcheck; + +cd "$workingDir"; +rm "$pkgName";