In the config file at
you will find lines that define the way you can lock, shutdown,… your system. Search for this code.
Here there is a small set of lines that will execute a different command with a different shortcut. It will go to the file i3exit.sh and will accept a parameter.
It will be come more clear in the movie. Just remember that the code in the config file is linked to the file i3exit.sh.
I rewrote the code to be more compliant to systemctl.