mirror of
https://github.com/jbranchaud/til
synced 2026-01-03 07:08:01 +00:00
Add Create A New Session In A New Server as a tmux til
This commit is contained in:
22
tmux/create-a-new-session-in-a-new-server.md
Normal file
22
tmux/create-a-new-session-in-a-new-server.md
Normal file
@@ -0,0 +1,22 @@
|
||||
# Create A New Session In A New Server
|
||||
|
||||
Any tmux command will, by default, be invoked against the `default`
|
||||
server. You can instruct tmux to perform commands against a different server
|
||||
with the `-L` flag and the name of the server.
|
||||
|
||||
If you name a server that doesn't already exist, tmux will create and start
|
||||
that server for you. So, if you want to start a new session in a new server,
|
||||
just run a command like the following:
|
||||
|
||||
```bash
|
||||
$ tmux -L pokemon_server new-session -s pokedex
|
||||
```
|
||||
|
||||
If you are to detach from this session, you will need to specify the name of
|
||||
the server in order to attach again:
|
||||
|
||||
```bash
|
||||
$ tmux -L pokemon_server attach -t pokedex
|
||||
```
|
||||
|
||||
See `man tmux` for more details.
|
||||
Reference in New Issue
Block a user