Merge pull request #91 from kqwyf/master

Enable user to set the path of tmux-resurrect's save.sh and remove the hard-coded path
pull/93/head
Bruno Sutic 2021-04-28 11:29:05 +02:00 committed by GitHub
commit c7f12ce825
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

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