Last active
February 17, 2021 19:48
-
-
Save olivierlemoal/bff45ab69925e702691d0797fd303fcb to your computer and use it in GitHub Desktop.
i3 script to toggle between last windows
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Moved to https://github.com/olivierlemoal/i3-swap-focus |
It looks like last ncat version has segfaults issues when using Unix sockets (nmap/nmap#2154 still unpatched in arch). Try using openbsd-netcat
like this instead :
bindsym $mod+Tab exec echo "swap_focus" | nc -w0 -U "$XDG_RUNTIME_DIR/i3/event-listener.sock"
Alternatively, you can use this ncat static build from ERNW.
Yes, it works now! Thank you for the fast reply and the script, I appreciate it.
Great script, I could need help to adapt it to only switch the focus of windows, which are on the same workspace. Thank you!
This gist seems to draw some attention, so I put it on a repo so you can open issues / PR :
https://github.com/olivierlemoal/i3-swap-focus
@stahlnow I updated the script so you can stay on workspace
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I can't seem to make this work. I have an installed and working i3ipc from pip, I have ncat (nmap), event-listener.py is executable (755) and is in /usr/local/bin/, I added the needed lines in my i3 config file and restarted my system multiple times with no success whatsoever. Running event-listener.py from the terminal returns no output or error. Is there anything else I should install? What am I missing here?