40 lines
1.1 KiB
Fish
Executable file
40 lines
1.1 KiB
Fish
Executable file
#!/bin/env fish
|
|
begin
|
|
set -l dir (status dirname)
|
|
source "$dir/../../Scripts/software.fish"
|
|
inherit "$dir/../../../Common/Software/logo-ls/main.fish"
|
|
|
|
function installSW -V dir
|
|
set -l dirName (realpath "$dir")
|
|
set -l contextRoot (mktemp -d)
|
|
set -l pkgName logo-ls
|
|
set -l patchName workaround.patch
|
|
|
|
if not type -q logo-ls
|
|
begin
|
|
pushd "$contextRoot" >/dev/null
|
|
yay -G -f "$pkgName"
|
|
cd "$pkgName"
|
|
cp "$dirName/$patchName" .
|
|
|
|
sed -i \
|
|
-e "/^source=(/s/source=(/\0$patchName /" \
|
|
-e "/^md5sums=(/s/^md5sums=(/\0SKIP /" \
|
|
-e "/^build() {/,/}/{" \
|
|
-e "/^[[:space:]]*cd/{" \
|
|
-e "a cat ../$patchName | patch --strip 1 --forward --merge" \
|
|
-e "}" \
|
|
-e "}" \
|
|
PKGBUILD
|
|
|
|
makepkg --noconfirm -si --force
|
|
popd >/dev/null
|
|
end
|
|
|
|
rm -rf "$contextRoot"
|
|
end
|
|
end
|
|
|
|
runInstaller $argv
|
|
end
|