The i3 FAQ has migrated to https://github.com/i3/i3/discussions. All content here is read-only.
Ask Your Question
0

Restart i3 with shell [SOLVED]

asked 2012-11-20 23:10:18 +0000

kajong0007 gravatar image

updated 2012-11-20 23:23:17 +0000

Is there any way to restart i3 from a terminal while preserving the current session?

I know i3 can be restarted with a command within i3, but I want to send a command from a terminal to the current i3 session (if at all possible). I want to restart i3 after returning from suspending my computer (the i3 bar freezes after suspending my computer), so I was going to make a systemd script for it.

I'm using 64-bit Arch Linux on a MacBook Air.

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
0

answered 2012-11-20 23:18:55 +0000

Michael gravatar image

You can send any command with i3-msg, so in your case, it’s:

i3-msg restart
edit flag offensive delete link more

Comments

Thanks! I was trying to use some kind of ridiculous combination of "i3-input" and "xdotool", which wasn't getting me anywhere, as you can imagine.

kajong0007 gravatar imagekajong0007 ( 2012-11-20 23:24:40 +0000 )edit

Question Tools

Stats

Asked: 2012-11-20 23:10:18 +0000

Seen: 2,901 times

Last updated: Nov 20 '12