tmux-continuum/docs/systemd_details.md

14 lines
997 B
Markdown
Raw Normal View History

2015-11-28 18:46:19 +00:00
# Systemd automatic start for tmux
2015-11-28 18:36:02 +00:00
2015-11-28 18:46:19 +00:00
The first time tmux starts when '@continuum-boot' is set to 'on' tmux-continuum will generate a user level systemd unit file which it will save to `${HOME}/.config/systemd/user/tmux.service` and enable it. From then on when that user logs in, either through a GUI session or on the console or via ssh, Systemd will start the tmux server.
2015-11-28 18:36:02 +00:00
2015-11-28 18:46:19 +00:00
The command used to start the tmux server is determined via the '@systemd_tmux_server_start_cmd' option that can be set in .tmux.conf. (Remember to reload your configuration with `tmux source ~/.tmux.conf` afterwards.
2015-11-28 18:36:02 +00:00
2015-11-30 08:13:59 +00:00
The default command to use is `new-session -d`. If you want more control over what sessions get started then you should set up your sessions in tmux.conf and set @systemd_tmux_server_start_cmd to 'start-server'
To control the tmux service you can use all the standard `systemctl` commands using the `--user` argument. eg to see if the tmux server has started:
systemctl --user status tmux.service
2015-11-28 18:46:19 +00:00