Compare commits

...

2 Commits

Author SHA1 Message Date
Bruno Sutic f5e554a31d
Merge pull request #100 from primeapple/master
Accept different tmux installation path in systemd unit file
2021-12-01 21:33:36 +01:00
Toni Müller 669c3cfcc3
different tmux installation paths for systemd 2021-12-01 15:16:27 +01:00
1 changed files with 3 additions and 2 deletions

View File

@ -11,6 +11,7 @@ template() {
local options="$@"
local content=""
local resurrect_save_script_path="$(get_tmux_option "$resurrect_save_path_option" "$(realpath ${CURRENT_DIR}/../../../tmux-resurrect/scripts/save.sh)")"
local tmux_path="$(which tmux)"
read -r -d '' content <<-EOF
[Unit]
@ -20,10 +21,10 @@ template() {
[Service]
Type=forking
Environment=DISPLAY=:0
ExecStart=/usr/bin/tmux ${systemd_tmux_server_start_cmd}
ExecStart=${tmux_path} ${systemd_tmux_server_start_cmd}
ExecStop=${resurrect_save_script_path}
ExecStop=/usr/bin/tmux kill-server
ExecStop=${tmux_path} kill-server
KillMode=none
RestartSec=2