1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41
|
#!/bin/sh
#
# Check that tasksel pick the correct desktop environment.
DEBIAN_FRONTEND=noninteractive
export DEBIAN_FRONTEND
error=0
success() { echo success: "$@"; }
error() { error=1; echo error: "$@"; }
echo debian-edu-install debian-edu-install/profile multiselect Workstation \
| debconf-set-selections
for desktop in kde gnome lxde xfce mate lxqt ; do
echo tasksel tasksel/desktop multiselect "$desktop" \
| debconf-set-selections
wanted="education-desktop-$desktop"
# Find the selected metapackages.
selected=$(/usr/lib/education-tasks/edu-tasksel-setup tasksel \
--new-install --test 2>&1 \
| tr " " "\n" \
| sort \
| grep education-desktop \
| grep -v education-desktop-other)
if [ "$(echo $selected |wc -w)" -eq 1 ] ; then
success "Only one desktop style selected for tasksel/desktop=$desktop"
else
error "Not only one desktop style selected for tasksel/desktop=$desktop: " $selected
fi
if echo $selected | grep -wq education-desktop-$desktop ; then
success "tasksel selected $wanted for installation with tasksel/desktop=$desktop." 1>&2
else
error "tasksel did not select $wanted for installation with tasksel/desktop=$desktop." 1>&2
fi
done
exit $error
|