diff options
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/fndSession | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/fndSession b/bin/fndSession index baf45da..5697a2d 100755 --- a/bin/fndSession +++ b/bin/fndSession @@ -4,6 +4,8 @@ LIST="SessionTypes" +TMP=$(/bin/mktemp /tmp/.kdm.XXXXXXX) + [ -x /usr/bin/kde ] && { LIST="$LIST=kde"; FIRST=yes } @@ -62,5 +64,5 @@ if [ $FIRST = "yes" ];then else LIST="$LIST=default;failsafe;" fi -sed "s/^SessionTypes.*/"$LIST"/" /usr/share/config/kdmrc > /tmp/$$.kdmrc && \ -mv /tmp/$$.kdmrc /usr/share/config/kdmrc +sed "s/^SessionTypes.*/"$LIST"/" /usr/share/config/kdmrc > $TMP && \ +mv $TMP /usr/share/config/kdmrc |