mirror of
https://gitlab.freedesktop.org/libfprint/libfprint.git
synced 2026-06-11 10:34:18 +00:00
debian/update-udev-triggers.sh: Use perl to replace file content
envsubst is nice but may be not installed and can be confusing, so let's use perl (+ printenv) to replace our file content.
This commit is contained in:
Vendored
+2
-2
@@ -3,7 +3,7 @@ set -e
|
||||
|
||||
srcdir="${GBP_SOURCES_DIR:-.}"
|
||||
debpath="$(dirname "$0")"
|
||||
autosuspend_file="$srcdir/data/autosuspend.hwdb"
|
||||
autosuspend_file="/tmp/autosuspend.hwdb"
|
||||
commands_lines=()
|
||||
|
||||
while IFS= read -r line; do
|
||||
@@ -18,7 +18,7 @@ export UDEVADM_TRIGGERS=$( IFS=$'\n'; echo -e "${commands_lines[*]}" )
|
||||
|
||||
for i in $debpath/libfprint-*.post*.in; do
|
||||
out="${i%.in}"
|
||||
envsubst < "$i" > "$out"
|
||||
perl -pe 's/\@UDEVADM_TRIGGERS\@/`printenv UDEVADM_TRIGGERS`/e' "$i" > "$out"
|
||||
|
||||
if [ -n "$GBP_BRANCH" ]; then
|
||||
if ! git diff-index --quiet HEAD -- "$out"; then
|
||||
|
||||
Reference in New Issue
Block a user