2021-05-14 14:37:35 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
HAS_ENABLED_KEY=''
|
|
|
|
HAS_CUSTOM_CONFIG=''
|
|
|
|
|
|
|
|
kwinrcname=`qtpaths --locate-file GenericConfigLocation kwinrc`
|
|
|
|
if [ -f "$kwinrcname" ]; then
|
|
|
|
if grep -q "\[Effect-kwin4_effect_translucency\]" "$kwinrcname"; then
|
|
|
|
HAS_CUSTOM_CONFIG=1
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
while read -r line; do
|
|
|
|
KEY="${line%=*}"
|
2021-09-21 14:49:02 +00:00
|
|
|
if [ "$KEY" = "kwin4_effect_translucencyEnabled" ]; then
|
2021-05-14 14:37:35 +00:00
|
|
|
HAS_ENABLED_KEY=1
|
|
|
|
fi
|
|
|
|
echo "$line"
|
|
|
|
done
|
|
|
|
|
|
|
|
if [ -n "$HAS_CUSTOM_CONFIG" ] && [ -z "$HAS_ENABLED_KEY" ]; then
|
|
|
|
echo "kwin4_effect_translucencyEnabled=true"
|
|
|
|
fi
|