Skip to content

Commit c7f12ce

Browse files
authored
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
2 parents 3845e73 + 4c84c40 commit c7f12ce

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/handle_tmux_automatic_start/systemd_enable.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ template() {
1010
shift
1111
local options="$@"
1212
local content=""
13+
local resurrect_save_script_path="$(get_tmux_option "$resurrect_save_path_option" "$(realpath ${CURRENT_DIR}/../../../tmux-resurrect/scripts/save.sh)")"
1314

1415
read -r -d '' content <<-EOF
1516
[Unit]
@@ -21,7 +22,7 @@ template() {
2122
Environment=DISPLAY=:0
2223
ExecStart=/usr/bin/tmux ${systemd_tmux_server_start_cmd}
2324
24-
ExecStop=${HOME}/.tmux/plugins/tmux-resurrect/scripts/save.sh
25+
ExecStop=${resurrect_save_script_path}
2526
ExecStop=/usr/bin/tmux kill-server
2627
KillMode=none
2728

0 commit comments

Comments
 (0)