Closed notwidow closed 10 months ago
What is the alias?
What is the alias?
the alias activate swaylock from my config in ~/.config/sway/scripts/lockscreen
What is the alias?
i keep all the sway config in ~/.config/sway so i just need to copy sway in ~/.config in new OS and run the shell script which install the required packages... but recently i added the command in my script which will automatically copy sway to .config and all done. I love shell scripts and automate my work with it. EDIT my alias name if you want is.
which executes the lockscreen file
What is the alias?
a tip for you. whenver write a shell script always write in shell and not bash or zsh etc. why? because bash is not installed in every os by default like openbsd but sh is installed in all unix os and your script will work in every unix -like os. !#/bin/sh
It's not actually "stuck" on the swaylock command, it just looks that way because it was run in detached mode by passing the -f
or --deamonize
flag. Check if this is the case for you by typing alias sl
in your terminal.
You could still run any command just fine even though it does not look that way:
➜ ~ swaylock -f
➜ ~ 2023-02-09 15:28:49 - [swaylock-1.7.2/pam.c:105] pam_authenticate failed: invalid credentials
echo "test"
test
➜ ~
Running swaylock without the flag would result in the output you'd expect:
➜ ~ swaylock
2023-02-09 15:30:39 - [swaylock-1.7.2/pam.c:105] pam_authenticate failed: invalid credentials
➜ ~ echo "test"
test
➜ ~
I am not sure what the desired behavior of a detached process is so I don't know if this is an issue or not. I can think of three behaviors:
Personally I would expect behavior 1.
If you want swaylock to block, yeah, you need to use the -f
flag. I think it's reasonable to still print any error message to stderr even if detached.
Hi, When i enter wrong password at first attempt then on second attempt after corect password. My terminal is still on the swaylock command. I have an alias which execute swaylock with my config. so when i type swaylock alias in terminal and then if the 1st attempt is not correct then on 2nd attempt it unlocks but my cursor still stuck on the swaylock command . i have to press ctrl+c to start another command.