no need for shell script anymore.
This commit is contained in:
parent
a241c45c72
commit
9836ee3d94
24
slocked
24
slocked
@ -1,24 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
ps=$(ps ux \
|
||||
| sed 1d \
|
||||
| grep -v tty1 \
|
||||
| grep -v pts \
|
||||
| grep -v '?' \
|
||||
| awk '{ print $2 }')
|
||||
|
||||
if test -n "$ps"; then
|
||||
echo "Killing: $ps"
|
||||
kill $ps 2> /dev/null
|
||||
kill -9 $ps 2> /dev/null
|
||||
fi
|
||||
|
||||
exec 2> /dev/null
|
||||
|
||||
if test -z "$1"; then
|
||||
exec slock -f ~/.slock_passwd
|
||||
exit 1
|
||||
fi
|
||||
|
||||
exec slock -p "$1"
|
||||
exit 1
|
Loading…
Reference in New Issue
Block a user