From: Michael Klemm <michael@dontknow.de>
To: zzapper <zsh@rayninfo.co.uk>, "zsh-users@zsh.org" <zsh-users@zsh.org>
Subject: RE: zsh : launch tmux in just one terminal
Date: Fri, 1 Oct 2021 17:19:36 +0000 [thread overview]
Message-ID: <f240833f43b044df83f59c9a9437c917@WINHEXBEEU117.win.mail> (raw)
In-Reply-To: <1d1fba0d-5769-8b7c-b8d8-c53a9df0c601@rayninfo.co.uk>
[-- Attachment #1: Type: text/plain, Size: 533 bytes --]
Hi,
> -----Original Message-----
> From: zsh-users-request@zsh.org <zsh-users-request@zsh.org> On Behalf Of
> zzapper
> Sent: Freitag, 1. Oktober 2021 18:55
> Thanks for both answers
>
> this seems to be what I need
>
> if pgrep "tmux" > /dev/null ; then echo "Running" ; else echo "Stopped" ;
> fi
That will only work if you're the only user of the system, who has tmux
processes. On multi-user machine with several tmux instances running for
different users, pgrep tmux will also match those.
Kind regards,
-michael
[-- Attachment #2: smime.p7s --]
[-- Type: application/pkcs7-signature, Size: 4429 bytes --]
next prev parent reply other threads:[~2021-10-01 17:20 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 [this message]
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
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=f240833f43b044df83f59c9a9437c917@WINHEXBEEU117.win.mail \
--to=michael@dontknow.de \
--cc=zsh-users@zsh.org \
--cc=zsh@rayninfo.co.uk \
/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).