Hey Scott, On Wed, Oct 2, 2019 at 5:44 PM Scott Rochford <[email protected]> wrote:
> Hi Matt, > > Like you, I work on many systems, however I only run tmux on the "most > local" system, and have key bindings set up to open fresh windows or panes > which connect immediately to remote systems, or even multiple systems (e.g. > a cluster) in a split window. > > To try to understand your requirement better, can you explain what > advantage (s) you find in running tmux on the most remote system? > Sure! System upgrades. Database dumps or creating indexes, etc. Rsyncs. Things that take a long time. I have had issues where my workstation would lock up and the controlling terminal would freeze and cause the remote process to die. So, I always like to have a tmux running where the most important process is running. This way the network or the workstation won't interfere with the completion of the job. > Is it because you frequently need multiple windows/panes on the remote > system that would be too inconvenient to spawn more ssh connections for? > If I am working on a remote system, sometimes I want to run another command on that system and it would be nice to split the pane and do that, but the local tmux takes the key sequence to split the pane. Then I need to ssh. It would be nice to have my configuration "just know what I want." Thanks, -m > > Scott > > On Thu., 3 Oct. 2019, 06:26 Matt Zagrabelny, <[email protected]> wrote: > >> Thanks for the answers Nicholas! >> >> Perhaps I should just state what I currently do and see if there is a >> more optimal way of achieving what I think I want. >> >> Right now for all of my computers I have tmux spawn when a shell is >> exec'ed. It is very nice to always have tmux running whenever I am in a >> shell and to not have to type: "tmux". >> >> The problem is when I ssh to other systems I then have two tmuxes running >> and I'd rather just have the one running on the remote system - so when I >> split a pane, I am doing all of my tmux commands on the "most remote" >> system and not have "more local" tmuxes interfere with the escape keys and >> not have to remember how many times I need to hit the escape sequence to >> get it to reach the "most remote" system. >> >> For instance: >> >> laptop (tmux) $ ssh workstation >> laptop (tmux) workstation (tmux) $ ssh home_server >> laptop (tmux) workstation (tmux) home_server (tmux) $ >> >> So that is three tmuxes I have running when really I just want: >> >> laptop workstation home_server (tmux) $ >> >> Or I would like my escape key binding to (default to?) send 3 escape keys >> if I have three tmuxes running. >> >> Any ideas or suggestions regarding my scenarios? >> >> Thanks! >> >> -m >> >> On Wed, Oct 2, 2019 at 2:46 PM Nicholas Marriott < >> [email protected]> wrote: >> >>> Hi >>> >>> tmux can't change the environment of other processes, including its >>> parent. >>> >>> You could possibly do it yourself with a script that detaches tmux, >>> usese tmux showenv and pane_current_path to update the parent shell, >>> then kills tmux. >>> >>> Alternatively it would possible to add a feature where tmux replaced >>> itself with a new shell with the updated environment but I don't see >>> much use for this so there is little chance of it being implemented. >>> >>> >>> On Wed, Oct 02, 2019 at 10:09:23AM -0500, Matt Zagrabelny wrote: >>> > Greetings, >>> > Is there a way to leave tmux, but somehow seed the environment >>> (history, >>> > CWD, etc.) with everything that was part of the tmux environment? >>> > Sort of like: >>> > tmux >>> > # do stuff >>> > tmux --copy-environment-exec-shell >>> > # now the shell is running without tmux >>> > What do you folks think? >>> > Thanks for any help! >>> > -m >>> > >>> > -- >>> > You received this message because you are subscribed to the Google >>> Groups >>> > "tmux-users" group. >>> > To unsubscribe from this group and stop receiving emails from it, >>> send an >>> > email to [email protected]. >>> > To view this discussion on the web, visit >>> > >>> https://groups.google.com/d/msgid/tmux-users/CAOLfK3V%2BVMY4br1fKfvXbjukAcdzV5pCAMjrHoq%2BuWkMqC%3D5nw%40mail.gmail.com >>> . >>> >> -- >> You received this message because you are subscribed to the Google Groups >> "tmux-users" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/tmux-users/CAOLfK3UWV5bE2283arT-BsnN_b5%2BLPz1637D72Bo9YEJ_ELQCA%40mail.gmail.com >> <https://groups.google.com/d/msgid/tmux-users/CAOLfK3UWV5bE2283arT-BsnN_b5%2BLPz1637D72Bo9YEJ_ELQCA%40mail.gmail.com?utm_medium=email&utm_source=footer> >> . >> > -- You received this message because you are subscribed to the Google Groups "tmux-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web, visit https://groups.google.com/d/msgid/tmux-users/CAOLfK3UN3YKt8Ys53Mpan%3D611jemKsL77sAwN%3DMULtFMPb-p%2BA%40mail.gmail.com.
