]> ruderich.org/simon Gitweb - config/dotfiles.git/blobdiff - shell/logout
shell/aliases: Replace remaining $* with "$@".
[config/dotfiles.git] / shell / logout
index 1a87b04be282ba842d60e5ed5a0b42f362a13117..491f594a589bd3eaa263803d5f96662aec31c33f 100644 (file)
@@ -3,12 +3,14 @@
 
 # When leaving the console clear the screen to increase privacy. Taken from
 # Debian default bash files and modified. Thanks.
-if [ "$SHLVL" = 1 ]; then
-    if [ -x /usr/bin/clear_console ]; then
-        /usr/bin/clear_console -q
-    else
-        clear
-    fi
+
+if [ -x /usr/bin/clear_console ]; then
+    /usr/bin/clear_console -q
+else
+    clear
 fi
 
+# Make sure sudo rights are removed.
+sudo -k > /dev/null 2>&1
+
 # vim: ft=sh