How do I use i3lock after autologin

Hi everyone!
I wanted to use i3lock both for the first login screen and for all the successive screen. The latter was easy, as it’s just a bindsym, but I’m having lots of problem for the former.
[I’m using zsh]

What I did:

First, I tried to autologin with lightdm but it didn’t work. I also tried with SDDM, but after I successfully set up the autologin and wrote the command to autostart my i3lock bash script [in .xprofile] I entered an hell where I could not escape (but I did, thanks to my trusted usb stick); jokes aside, it was a loop where after I logged in (through i3lock) I had another SDDM login screen, and then another i3lock and so forth…
Thus I used the tty login method, I setup the autologin and the autostart for i3 in .xinitrc. And it works!.. almost. I can’t get the i3lock script to load after i3 is started for the first time and now the unimatrix command I launch through the i3’s config file does nothing (if I start it on a new kitty instance it works just fine though, also it’s not freezed).
I tried to achieve the i3lock autostart by writing in ~/.xinitrc the following:

  1. exec sh home/myUsername/i3/i3lock.sh
  2. exec home/myUsername/i3/i3lock.sh
  3. source home/myUsername/i3/i3lock.sh

What I’d like to do:

When I log in for the first time I’d like to be welcomed by the i3lock screen. And I’d like unimatrix to work as well!

Why don’t you just put it in i3 config file?
I have it at /home/myUsername/.config/i3/config but yours may be at slightly different location.
exec --no-startup-id /home/myUsername/i3/i3lock.sh
I cannot predict what will it do since I do not know content of that i3lock.sh file.

Also, I do not know if it is intentional but your script examples above starts with home and not /home so it probably looks for a script at /home/myUsername/home/myUsername/i3/i3lock.sh.

yes this should work, make sure the script is working