pmaports/hybris/pulseaudio-modules-droid/pulseaudio-modules-droid.post-install
Alexey Min e38f1de121
hybris/pulseaudio-modules-droid: new package (!448)
Set of pulseaudio modules that use Android audio HAL
(via libhybris) to talk to sound cards.

[ci:skip-build]: already built successfully in CI
2019-07-09 22:49:03 +02:00

20 lines
373 B
Bash
Executable file

#!/bin/sh
# pulseaudio default config file name
DEFAULT_PA=/etc/pulse/default.pa
# configuration lines
L1="load-module module-droid-card"
append_line() {
FN=$1
LINE=$2
if ! grep -q "${LINE}" "${FN}"; then
echo "Adding $LINE..."
echo "${LINE}" >> "${FN}"
else
echo "Not adding ${LINE}"
fi
}
if [ -f ${DEFAULT_PA} ]; then
append_line "${DEFAULT_PA}" "${L1}"
fi