2

According to i3 documentation : i3 append layout system append_layout program should be available since i3 4.8

I don't have the append_layout i3 program in my path.

sudo find / -name "append_layout" | wc -l
0

my linux version is a Debian Jessie up to date

uname -a
Linux Sphinx 3.16.0-4-amd64 #1 SMP Debian 3.16.36-1+deb8u1 (2016-09-03) x86_64 GNU/Linux

and

i3 --version
i3 version 4.8 (2014-06-15, branch "4.8") © 2009-2014 Michael Stapelberg and contributors

I don't mind where to find this program or if I missed a package setup on my linux.

Someone has an idea ?

Martijn Pieters
  • 1,048,767
  • 296
  • 4,058
  • 3,343
utopman
  • 581
  • 4
  • 13

1 Answers1

3

append_layout is an internal command of i3 and not an external (command line) command.

In order to use it, you have to either use the i3-msg command line tool (or some other i3 IPC library):

i3-msg append_layout /PATH/TO/LAYOUT.json

or you can bind it to a shortcut in your i3 configuration (~/.config/i3/config or ~/.i3/config):

bindsym Mod4+a append_layout /PATH/TO/LAYOUT.json 

If you want to autoload a layout on i3 startup, you can do so by running i3-msg via an exec configuration option:

exec --no-startup-id "i3-msg 'workspace 1; append_layout /PATH/TO/LAYOUT.json'"

Note the double quotes around the whole i3-msg command, which are needed to quote ; from the i3 configuration parser and the single quotes around the arguments to i3-msg, which are needed to quote ; from the shell running the command.

Ingo Bürk
  • 19,263
  • 6
  • 66
  • 100
Adaephon
  • 16,929
  • 1
  • 54
  • 71
  • Thank you for your answer. It works now for me. But now I have to find how to run the programs into each tab as the loaded layout display black windows. – utopman Oct 19 '16 at 07:47
  • Just starting the corresponding application should be enough. If a new window matches the criteria on a placeholder container, it will be swallowed automatically. – Adaephon Oct 19 '16 at 12:01
  • You don't seem to need the outer level of quotes at all. `exec --no-startup-id i3-msg "workspace 1; append_layout ..."` works fine. – tremby Nov 09 '21 at 22:08