You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Problem Description : Currently when I am about to end my session I manually loop through entire windows and panes in the session and manually type in Alt+Shift+P to create a new directory and save my logs in that directory which then saves this in the naming convention that suits my needs.
Proposition : If at all is it possible to create a key bind say Shift+Alt+S to save the entire logs of a session in one single go i.e to say it will iterate to all windows and panes in them and log them individually to the directory in which the tmux session was started ?
The text was updated successfully, but these errors were encountered:
I researched and found something. Unfortunately its not working as I desired it to work. Below is what I did. If somebody can enlighten me with what I am doing wrong.
Created a new file save_complete_history_all_panes.sh in .tmux-logging/scripts
#!/usr/bin/env bash
CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source "$CURRENT_DIR/variables.sh"
source "$CURRENT_DIR/shared.sh"
main() {
if supported_tmux_version_ok; then
local file=$(expand_tmux_format_path "${save_complete_history_full_filename}")
local history_limit="$(tmux display-message -p -F "#{history_limit}")"
for _window in $(tmux list-windows -F '#I'); do
for _pane in $(tmux list-panes -t ${_window} -F '#P'); do
tmux capture-pane -J -S "-${history_limit}" -p > "${file}"
display_message "History saved to ${file}"
done
done
fi
}
main
Create a new key-bind in .tmux-logging/scripts/variables.sh :
# Complete history capture in all panes.
default_save_complete_history_all_panes_key="M-S" # Alt+Shift+S
save_complete_history_all_panes_key=$(tmux show-option -gqv "@save-complete-history-all-panes")
save_complete_history_all_panes_key=${save_complete_history_all_panes_key:-$default_save_complete_history_all_panes_key}
I thought this should work. Logically speaking it definitely should unfortunately it only captures the pane the key-bind was pressed in. If someone can help/guide me what I am doing wrong. @majedchams@bruno-
Thank you for this outstanding plugin.
Problem Description : Currently when I am about to end my session I manually loop through entire windows and panes in the session and manually type in
Alt+Shift+P
to create a new directory and save my logs in that directory which then saves this in the naming convention that suits my needs.Proposition : If at all is it possible to create a key bind say
Shift+Alt+S
to save the entire logs of a session in one single go i.e to say it will iterate to all windows and panes in them and log them individually to the directory in which the tmux session was started ?The text was updated successfully, but these errors were encountered: