mirror of
				https://github.com/tmux/tmux.git
				synced 2025-11-04 00:56:10 +00:00 
			
		
		
		
	Merge branch 'obsd-master'
This commit is contained in:
		@@ -96,6 +96,12 @@ const struct options_table_entry options_table[] = {
 | 
			
		||||
	  .default_num = 500
 | 
			
		||||
	},
 | 
			
		||||
 | 
			
		||||
	{ .name = "exit-empty",
 | 
			
		||||
	  .type = OPTIONS_TABLE_FLAG,
 | 
			
		||||
	  .scope = OPTIONS_TABLE_SERVER,
 | 
			
		||||
	  .default_num = 1
 | 
			
		||||
	},
 | 
			
		||||
 | 
			
		||||
	{ .name = "exit-unattached",
 | 
			
		||||
	  .type = OPTIONS_TABLE_FLAG,
 | 
			
		||||
	  .scope = OPTIONS_TABLE_SERVER,
 | 
			
		||||
 
 | 
			
		||||
@@ -905,6 +905,7 @@ server_client_handle_key(struct client *c, key_code key)
 | 
			
		||||
	 * The prefix always takes precedence and forces a switch to the prefix
 | 
			
		||||
	 * table, unless we are already there.
 | 
			
		||||
	 */
 | 
			
		||||
retry:
 | 
			
		||||
	key0 = (key & ~KEYC_XTERM);
 | 
			
		||||
	if ((key0 == (key_code)options_get_number(s->options, "prefix") ||
 | 
			
		||||
	    key0 == (key_code)options_get_number(s->options, "prefix2")) &&
 | 
			
		||||
@@ -915,7 +916,6 @@ server_client_handle_key(struct client *c, key_code key)
 | 
			
		||||
	}
 | 
			
		||||
	flags = c->flags;
 | 
			
		||||
 | 
			
		||||
retry:
 | 
			
		||||
	/* Log key table. */
 | 
			
		||||
	if (wp == NULL)
 | 
			
		||||
		log_debug("key table %s (no pane)", table->name);
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										3
									
								
								server.c
									
									
									
									
									
								
							
							
						
						
									
										3
									
								
								server.c
									
									
									
									
									
								
							@@ -254,6 +254,9 @@ server_loop(void)
 | 
			
		||||
 | 
			
		||||
	server_client_loop();
 | 
			
		||||
 | 
			
		||||
	if (!options_get_number(global_options, "exit-empty") && !server_exit)
 | 
			
		||||
		return (0);
 | 
			
		||||
 | 
			
		||||
	if (!options_get_number(global_options, "exit-unattached")) {
 | 
			
		||||
		if (!RB_EMPTY(&sessions))
 | 
			
		||||
			return (0);
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										5
									
								
								tmux.1
									
									
									
									
									
								
							
							
						
						
									
										5
									
								
								tmux.1
									
									
									
									
									
								
							@@ -2507,6 +2507,11 @@ Set the time in milliseconds for which
 | 
			
		||||
waits after an escape is input to determine if it is part of a function or meta
 | 
			
		||||
key sequences.
 | 
			
		||||
The default is 500 milliseconds.
 | 
			
		||||
.It Xo Ic exit-empty
 | 
			
		||||
.Op Ic on | off
 | 
			
		||||
.Xc
 | 
			
		||||
If enabled (the default), the server will exit when there are no active
 | 
			
		||||
sessions.
 | 
			
		||||
.It Xo Ic exit-unattached
 | 
			
		||||
.Op Ic on | off
 | 
			
		||||
.Xc
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user