You are not logged in.

#1 2022-03-31 11:35:45

Manix
Member
Registered: 2021-04-17
Posts: 81

[SOLVED]xss-lock problem

Hello,
I use xss-lock with a script to lock my screen, it works quite well, however when I execute my script manually xss-lock triggers and indicates a "lock failed".

script i3lock :

#!/bin/sh

B='#2e344000'  # blank
C='#88c0d022'  # clear ish
D='#88c0d0cc'  # default
T='#81a1c1ee'  # text
W='#991d1fbb'  # wrong
V='#88c0d0'  # verifying

i3lock \
--insidever-color=$C \
--ringver-color=$V \
\
--insidewrong-color=$C \
--ringwrong-color=$W \
\
--inside-color=$B \
--ring-color=$D \
--line-color=$B \
--separator-color=$D \
\
--verif-color=$T \
--wrong-color=$T \
--time-color=$T \
--date-color=$T \
--layout-color=$T \
--keyhl-color=$W \
--bshl-color=$W \
\
--ind-pos="180:540" \
--screen 1 \
--blur 6 \
--clock \
--indicator \
--time-str="%H:%M:%S" \
--date-str="%A" \
#--keylayout 1 \

bspwmrc :

...
xset s 300 0 &
xss-lock $HOME/.config/lock.sh &
#xss-lock $HOME/.config/lock.sh +resetsaver &
...

I tried with the +resetsaver option, same result.

xset -q :

Keyboard Control:
  auto repeat:  on    key click percent:  0    LED mask:  00000002
  XKB indicators:
    00: Caps Lock:   off    01: Num Lock:    on     02: Scroll Lock: off
    03: Compose:     off    04: Kana:        off    05: Sleep:       off
    06: Suspend:     off    07: Mute:        off    08: Misc:        off
    09: Mail:        off    10: Charging:    off    11: Shift Lock:  off
    12: Group 2:     off    13: Mouse Keys:  off
  auto repeat delay:  660    repeat rate:  25
  auto repeating keys:  00ffffffdffffbbf
                        fedfffefffedffff
                        9fffffffffffffff
                        fff7ffffffffffff
  bell percent:  50    bell pitch:  400    bell duration:  100
Pointer Control:
  acceleration:  2/1    threshold:  4
Screen Saver:
  prefer blanking:  yes    allow exposures:  yes
  timeout:  300    cycle:  0
Colors:
  default colormap:  0x20    BlackPixel:  0x0    WhitePixel:  0xffffff
Font Path:
  built-ins
DPMS (Energy Star):
  Standby: 0    Suspend: 0    Off: 600
  DPMS is Enabled
  Monitor is On

is it possible to disable xss-lock if I run my script manually?
the manpage is very sparse and not very comprehensible.
thank you!

Last edited by Manix (2022-03-31 19:30:10)


I don't love rosbeef

Offline

#2 2022-03-31 12:20:26

progandy
Member
Registered: 2012-05-17
Posts: 5,319

Re: [SOLVED]xss-lock problem

You can start the screensaver with "xset s activate", then xss-lock will run it for you.


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' | alias ENGLISH='LANG=C.UTF-8 ' |

Offline

#3 2022-03-31 13:07:53

Manix
Member
Registered: 2021-04-17
Posts: 81

Re: [SOLVED]xss-lock problem

You can start the screensaver with "xset s activate", then xss-lock will run it for you.

Hello,
if I indicate "xset s activate" I lose the TIMEOUT and the CYCLE. how to fix this if I want my screen to lock after 5 minutes? (assuming I didn't run my script for the lock)
thx


I don't love rosbeef

Offline

#4 2022-03-31 13:19:23

progandy
Member
Registered: 2012-05-17
Posts: 5,319

Re: [SOLVED]xss-lock problem

Keep your current setup just as it is with the timeout. Only use "xset s activate" instead of calling your script directly to lock it manually. That should not change your timeout.


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' | alias ENGLISH='LANG=C.UTF-8 ' |

Offline

#5 2022-03-31 13:45:21

Manix
Member
Registered: 2021-04-17
Posts: 81

Re: [SOLVED]xss-lock problem

Keep your current setup just as it is with the timeout. Only use "xset s activate" instead of calling your script directly to lock it manually. That should not change your timeout.

"xset s activate" works instead of calling the script however I still have the same problem, if I lock manually via "xset s activate" xss-lock tries again to lock the session after 5 min.


I don't love rosbeef

Offline

#6 2022-03-31 18:38:14

Raynman
Member
Registered: 2011-10-22
Posts: 1,539

Re: [SOLVED]xss-lock problem

Your script seems to start i3lock in forking mode (which is the default) and the xss-lock man page says the command should not fork. Because of the forking, xss-lock thinks the locker exited and should be (re)started after the 5 min timeout.

Offline

#7 2022-03-31 19:29:40

Manix
Member
Registered: 2021-04-17
Posts: 81

Re: [SOLVED]xss-lock problem

Your script seems to start i3lock in forking mode (which is the default) and the xss-lock man page says the command should not fork. Because of the forking, xss-lock thinks the locker exited and should be (re)started after the 5 min timeout.

good evening
The problem came from there, by adding -n to i3lock, xss-lock no longer tries to lock the screen after 5 min and runs fine if I don't lock manually smile
thank you very much, solved.


I don't love rosbeef

Offline

Board footer

Powered by FluxBB