2021-05-11 17:54:47 +02:00
|
|
|
#!/bin/sh
|
|
|
|
# stdin: default config
|
|
|
|
# stdout: modified config
|
2021-07-02 12:50:24 +02:00
|
|
|
set -e
|
2021-05-11 17:54:47 +02:00
|
|
|
|
2021-06-18 19:32:30 +02:00
|
|
|
# save stdin in variable
|
2021-07-02 12:50:24 +02:00
|
|
|
stdin="$(cat)"
|
2021-06-18 19:32:30 +02:00
|
|
|
|
|
|
|
# assert WindowScalingFactor is as expected
|
|
|
|
echo "$stdin" | grep --quiet '<property name="WindowScalingFactor" type="int" value="1"/>'
|
|
|
|
|
|
|
|
# assert CursorThemeSize is as expected
|
|
|
|
echo "$stdin" | grep --quiet '<property name="CursorThemeSize" type="int" value="0"/>'
|
|
|
|
|
|
|
|
# 1. Double WindowScalingFactor
|
|
|
|
# 2.Increase cursor size to 32
|
2021-07-02 12:50:24 +02:00
|
|
|
echo "$stdin" | sed '
|
2021-06-18 19:32:30 +02:00
|
|
|
s|<property name="WindowScalingFactor" type="int" value="1"/>|<property name="WindowScalingFactor" type="int" value="2"/>|;
|
|
|
|
s|<property name="CursorThemeSize" type="int" value="0"/>|<property name="CursorThemeSize" type="int" value="32"/>|;
|
2021-07-02 12:50:24 +02:00
|
|
|
'
|