summaryrefslogtreecommitdiffstats
path: root/core/modules/printergui/data/opt/openslx/scripts/systemd-printergui_preparation
blob: 299716664c44d471e037b5014096e4b9a205a35f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/ash

ERR=0
SRCDIR=/usr/lib/cups/backend
DESTDIR=/opt/openslx/cups/backend
PRINTPWGUI=/opt/openslx/cups/printpwgui

if [ ! -d "$DESTDIR" ]; then
	mkdir -p "$DESTDIR" || exit 1
fi

mv -n "$SRCDIR"/* "$DESTDIR"

cd "$SRCDIR"
for i in "$DESTDIR"/*; do
        ln -s "$PRINTPWGUI" $(basename "$i")
done

exit 0