Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "attach-session -x" and "new-session -AX" #1773

Closed
wants to merge 1 commit into from

Conversation

@cjwatson
Copy link

cjwatson commented Jun 3, 2019

These are roughly the equivalent of "screen -D -r" and "screen -D -R"
respectively (except that new-session also needs to be given a session
name). The primitive for this was already available via detach-client,
but it wasn't in the most convenient form if you wanted to attach,
detach all other clients, and send SIGHUP to the parents of all other
clients in a single operation.

The best choice of option letter was a little unclear. detach-client
uses -P, but that felt odd in this context where it's clearly a minor
variation of -d/-D (and it doesn't make sense to require users to type
both). Both -D and -P were already taken in new-session. In the end I
felt that making attach-session and new-session be similar was more
important than making either be exactly like detach-client, so I went
for -x/-X by analogy with the keys available in client mode.

These are roughly the equivalent of "screen -D -r" and "screen -D -R"
respectively (except that new-session also needs to be given a session
name).  The primitive for this was already available via detach-client,
but it wasn't in the most convenient form if you wanted to attach,
detach all other clients, and send SIGHUP to the parents of all other
clients in a single operation.

The best choice of option letter was a little unclear.  detach-client
uses -P, but that felt odd in this context where it's clearly a minor
variation of -d/-D (and it doesn't make sense to require users to type
both).  Both -D and -P were already taken in new-session.  In the end I
felt that making attach-session and new-session be similar was more
important than making either be exactly like detach-client, so I went
for -x/-X by analogy with the keys available in client mode.
@nicm

This comment has been minimized.

Copy link
Member

nicm commented Jun 3, 2019

Great stuff, applied, thanks!

@nicm nicm closed this Jun 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.