Skip to content
Snippets Groups Projects
Unverified Commit 8c2c15cd authored by Oliver Smith's avatar Oliver Smith
Browse files

tinydm-set-session: be quiet if already set

Don't print the "Session already set to" message if the new session is
the same as the old one. That way it doesn't get printed anymore
whenever upgrading one of the postmarketos-ui-* packages that use
tinydm.
parent 55e8defe
No related branches found
Tags 1.1.3
No related merge requests found
Pipeline #143722 passed
......@@ -26,6 +26,12 @@ mkdir -p /var/lib/tinydm
target="/var/lib/tinydm/default-session.desktop"
session_old=$(readlink -f $target)
# Be quiet in post-install scripts if the desired session is already set
if [ "$session_old" = "$session" ]; then
exit 0
fi
if [ -e "$session_old" ] && ! $force; then
echo "tinydm: Session already set to: $session_old"
echo "tinydm: To change it, run: 'tinydm-set-session -f -s $session'"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment