From 2187f29a7d6a64e33ca78fc44a3d98e03bd4fc3b Mon Sep 17 00:00:00 2001 From: mhiretskiy Date: Tue, 2 Jun 2009 13:51:09 +0000 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BA=D0=B8?= =?UTF-8?q?=20=D1=81=D0=B2=D1=8F=D0=B7=D0=B0=D0=BD=D0=BD=D0=BE=D0=B9=20?= =?UTF-8?q?=D1=81=20=D0=BE=D1=82=D0=BC=D0=BE=D0=BD=D1=82=D0=B8=D1=80=D0=BE?= =?UTF-8?q?=D0=B2=D0=B0=D0=BD=D0=B8=D0=B5=D0=BC=20=D0=B4=D0=BE=D0=BC=D0=B5?= =?UTF-8?q?=D0=BD=D0=BD=D1=8B=D1=85=20=D1=80=D0=B5=D1=81=D1=83=D1=80=D1=81?= =?UTF-8?q?=D0=BE=D0=B2,=20=D0=BF=D1=80=D0=B8=20=D0=B2=D1=8B=D1=85=D0=BE?= =?UTF-8?q?=D0=B4=D0=B5=20=D0=B8=D0=B7=20=D1=81=D0=B5=D0=B0=D0=BD=D1=81?= =?UTF-8?q?=D0=B0=20=D0=BF=D0=BE=20Ctrl+Alt+Backspace=20=D0=B2=20XFCE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: http://svn.calculate.ru/calculate2/calculate-client/trunk@1605 c91db197-33c1-4113-bf15-f8a5c547ca64 --- data/login | 12 ++++++++++++ profile/install/client/etc/slim.conf | 4 ++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/data/login b/data/login index f90a043..14cdcee 100644 --- a/data/login +++ b/data/login @@ -6,6 +6,18 @@ xmes() { $2" | iconv -f utf8 -t koi8-r - | xargs xmessage -buttons OK:0 -default OK } +if [[ "`ps axeo command | grep xdm/logout | grep -v grep | \ + sed -n -r 's/.* USER=([^ ]+) .*/\1/p'`" == "$USER" ]]; +then + xmessage -buttons "" "Please wait to ending previous session" & + while [[ "`ps axeo command | grep xdm/logout | grep -v grep | \ + sed -n -r 's/.* USER=([^ ]+) .*/\1/p'`" == "$USER" ]] + do + sleep 1 + done + kill -9 `ps ax | sed -n -r '/grep/!{s/([0-9]+) .*xmessage -buttons Please.*/\1/p}'` &>/dev/null +fi + env-update source /etc/profile diff --git a/profile/install/client/etc/slim.conf b/profile/install/client/etc/slim.conf index b62a2b2..ef9842f 100644 --- a/profile/install/client/etc/slim.conf +++ b/profile/install/client/etc/slim.conf @@ -3,10 +3,10 @@ #?cl_pass_step==install# login_cmd if ! /usr/share/calculate/xdm/cmd_login ; then exit 1; fi && exec /bin/bash -login /etc/X11/xinit/xinitrc sessionstart_cmd export USER=%user && /usr/share/calculate/xdm/login && /usr/bin/sessreg -a -l :0.0 %user -sessionstop_cmd export USER=%user && /usr/share/calculate/xdm/logout && /usr/bin/sessreg -d -l :0.0 %user +sessionstop_cmd export USER=%user && start-stop-daemon --start --exec /usr/share/calculate/xdm/logout && /usr/bin/sessreg -d -l :0.0 %user #cl_pass_step# #?cl_pass_step==uninstall# login_cmd exec /bin/bash -login /etc/X11/xinit/xinitrc sessionstart_cmd /usr/bin/sessreg -a -l :0.0 %user sessionstop_cmd /usr/bin/sessreg -d -l :0.0 %user -#cl_pass_step# \ No newline at end of file +#cl_pass_step#