From: Steve Dondley <s@dondley.com>
To: Ray Andrews <rayandrews@eastlink.ca>
Cc: zsh-users@zsh.org
Subject: Re: zsh : launch tmux in just one terminal
Date: Sat, 02 Oct 2021 12:04:50 -0400 [thread overview]
Message-ID: <74ea8a45b988a72ca2e479fa7d3b6db9@dondley.com> (raw)
In-Reply-To: <72f7ba85-cdb8-9ba1-910f-3fc77f107a3c@eastlink.ca>
> I wrote a program that jumps my mouse pointer from one terminal to the
> next via hotkeys. Yeah, when you're in terminal mode, having to reach
> for the mouse just to move from one to the other is really annoying.
> Sounds like tmux handles this itself, but will it jump between
> monitors? And my program works regardless of the running applications
> so whereas it mostly for use in terminals I can jump between, say a
> browser and my email too.
You can have multiple tmux sessions on one computer. So you culd
dedicate terminal "A" to tmux session "A" and have terminal "B" show
tmux session "B" and just use hot keys to switch between them like you
currently do.
And tmux is fully scriptable. So let's say you want to send a command
from one pane in session A to another pane in session B, you can do this
with a tmux hotkey without even leaving the current terminal. It's very
powerful. I've used feature when I do testing. I'll punch a key and it
will test the code in the current pane in a completely different
terminal window running in a different tmux session.
I'm on a mac and I use iterm, which is just a terminal with more bells
and whistles. I have two monitors. I typically have 3 terminal windows
open: a vim session open for taking notes, a zsh session for running
taskwarrior commands, and one with tmux open for all my coding and
server administration. Within the session, you can have multiple
windows. I like to use windows for my different projects. So if I want
to switch to project "A", I hit a tmux hot key to jump to window "A" and
all the important files are right there, already open in vim and ready
for editing. Each file is in its own tmux pane, which is running it's
own separate shell.
At any rate, my notes and tasks are on one display, the tmux session is
full screen on the other. I use simple hot keys to change focus from one
terminal window to the other. For other applications like my browser, I
have hotkeys for those as well.
Well, that's probably more than you wanted to know. Like with anything,
only you can decide if using tmux is worth the investment of time in
learning it. If this is what you do for a living, then yeah, you should
definitely look into tmux as it will likely pay off. If you're more of a
casual user and just like puttering around on your computer for fun are
writing simple scripts and issuing a few dozen commands here and there
over the course of a day, it's probably overkill.
next prev parent reply other threads:[~2021-10-02 16:05 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-01 10:47 zzapper
2021-10-01 13:25 ` Marc Chantreux
2021-10-01 13:30 ` Steve Dondley
2021-10-01 16:54 ` zzapper
2021-10-01 17:19 ` Michael Klemm
2021-10-01 17:43 ` Bart Schaefer
2021-10-01 20:16 ` Ray Andrews
2021-10-01 20:34 ` zzapper
2021-10-01 20:53 ` Steve Dondley
2021-10-01 23:06 ` Ray Andrews
2021-10-02 4:52 ` Steve Dondley
2021-10-02 14:40 ` Ray Andrews
2021-10-02 16:04 ` Steve Dondley [this message]
2021-10-02 19:09 ` Ray Andrews
2021-10-01 23:03 ` Ray Andrews
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=74ea8a45b988a72ca2e479fa7d3b6db9@dondley.com \
--to=s@dondley.com \
--cc=rayandrews@eastlink.ca \
--cc=zsh-users@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).