summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/server.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Tidy old jobs every hour instead of every 30 seconds.nicm2021-03-111-5/+23
|
* Add a couple of helper functions, and flush imsgs on exit.nicm2021-02-111-22/+9
|
* Fix some warnings, GitHub issue 2382.nicm2020-09-161-4/+6
|
* Add a flag to make a client wait for an empty line before exiting innicm2020-06-181-2/+2
| | | | control mode to avoid stray commands ending up in the shell.
* Instead of sending all data to control mode clients as fast as possible,nicm2020-06-011-4/+3
| | | | | | add a limit of how much data will be sent to the client and try to use it for panes with some degree of fairness. GitHub issue 2217, with George Nachman.
* xterm-keys has been on by default for five years and all other modernnicm2020-05-161-1/+2
| | | | | | terminals use these key sequences by default. Merge the code into the main tty and input tree processing (converting the latter to use a tree rather than a table at the same time) and make the option a no-op.
* Add a -D flag to ask tmux not to daemonize, useful both for running anicm2020-05-161-18/+28
| | | | | debugger (lldb does not have follow-fork-mode) and for running with a managed supervisor init system. GitHub issue 2190.
* Change message log to be per server rather than per client and includenicm2020-05-161-1/+36
| | | | every command that is run.
* Add 'e' key in buffer mode to open the buffer in an editor.nicm2020-05-161-1/+2
|
* When the server socket is given by the user with -S, create it withnicm2020-03-121-7/+12
| | | | | | umask 177 instead of 117 because it may not be in a safe directory like the default directory in /tmp. The user can chmod it more open after it is created if they want.
* Expand command formats in %if and move the config file loading later (tonicm2019-06-201-3/+2
| | | | | when the first client has identified) so all the client formats are available, fixes problems reported by Thomas Sattler.
* Do not load the config file if the server is exiting because it failednicm2019-06-071-5/+7
| | | | | | to start, otherwise commands like lsk which start the server again can end up looping infinitely. Also make the first client exit correctly. Problem reported by Wael M Nasreddine.
* Replace the various identical error callbacks with a single one in cmd-queue.c.nicm2019-05-201-14/+3
|
* Break new window and pane creation common code from various commands andnicm2019-04-171-2/+2
| | | | window.c into a separate file spawn.c.
* Move job struct into job.c.nicm2018-08-231-21/+6
|
* SESSION_UNATTACHED flag is no longer necessary now we have an attachednicm2018-08-181-2/+2
| | | | count instead.
* session_groups can be static also.nicm2018-08-021-2/+1
|
* Add a missing client-detached hook when the server shuts down, and donicm2018-03-081-2/+11
| | | | | not exit until jobs started from run-shell/if-shell have finished (add a job flags member and a flag to indicate other jobs). GitHub issue 1245.
* Add exit-empty option to exit server if no sessions (defaults to on).nicm2018-02-221-1/+4
|
* Report better error from server when socket create fails, GitHub issuenicm2017-12-191-15/+43
| | | | 1201.
* Show exit status and time in the remain-on-exit pane text, mostly fromnicm2017-10-121-1/+2
| | | | Timo Boettcher in GitHub issue 1103.
* Because ignore SIGCHLD early, letting signal_del restore it doesn't worknicm2017-07-141-2/+2
| | | | | correctly, so set it explicitly back to default (and the others for good measure).
* Block signals between forking and clearing signal handlers (or callingnicm2017-07-121-2/+6
| | | | | | event_reinit) - if the child gets a signal and fires the libevent signal handler during this period it could write a signal into the parent's signal pipe. GitHub issue 1001 from Aaron van Geffen.
* Move signal code into proc.c.nicm2017-07-121-4/+17
|
* Some extra logging to show why tmux might exit.nicm2017-07-091-2/+3
|
* Do not close panes until process has exited and any outstanding datanicm2017-07-031-2/+7
| | | | has been written to the pipe-pane event if there is one. GitHub issue 991.
* Support SIGUSR2 to stop and start logging for an existing server. Alsonicm2017-06-041-2/+5
| | | | | we currently only have two log levels so just use -v and -vv rather than -v and -vvvv, and clarify the man page entry for -v.
* Memory leaks, from David CARLIER.nicm2017-04-221-3/+7
|
* Make the cmd_find_* functions more obvious when looking for a client,nicm2017-04-211-3/+3
| | | | | rather than having it inside other functions. Should be no change to the way targets are resolved just yet.
* History needs to be loaded after config parsing is done - now thatnicm2017-04-211-3/+1
| | | | commands are queued, that's in cfg_done not after start_cfg finishes.
* If a #() command doesn't exit, use its most recent line of output (itnicm2017-04-201-3/+10
| | | | | | | must be a full line). Don't let it redraw the status line more than once a second. Requested by someone about 10 years ago...
* Instead of numbering session groups, give them a name which may be givennicm2017-02-091-2/+2
| | | | | to -t instead of a target session. Also allow them to contain only one session.
* Fixed keys for choose mode, and remove the last mode keys bits.nicm2017-01-241-2/+1
|
* Do not execute commands for a client until it has identified, fixesnicm2016-11-121-3/+5
| | | | problem reported by Frank Terbeck.
* Notifys can go via the command queue instead of using their own queue.nicm2016-10-161-3/+1
|
* Rewrite command queue handling. Each client still has a command queue,nicm2016-10-161-2/+10
| | | | | | | | | | | | | | | but there is also now a global command queue. Instead of command queues being dispatched on demand from wherever the command happens to be added, they are now all dispatched from the top level server loop. Command queues may now also include callbacks as well as commands, and items may be inserted after the current command as well as at the end. This all makes command queues significantly more predictable and easier to use, and avoids the complex multiple nested command queues used by source-file, if-shell and friends. A mass rename of struct cmdq to a better name (cmdq_item probably) is coming.
* Drain notifys once at the end of the server loop instead of doing itnicm2016-10-151-1/+2
| | | | from the end of every command queue (which could be nested).
* Loads more static, except for cmd-*.c and window-*.c.nicm2016-10-101-21/+20
|
* tmux: only consider ACCESSPERMS for setting mode on socket_path.semarie2016-07-071-2/+2
| | | | | | | it explicitly removes any S_ISUID|S_ISGID|S_ISTXT bits, instead of letting pledge(2) silenciously remove them. ok nicm@ beck@ deraadt@
* Bump the listen() backlog up, some people have scripts that run up a lotnicm2016-03-301-2/+2
| | | | of clients quickly.
* I no longer use my SourceForge address so replace it.nicm2016-01-191-2/+2
|
* Add infrastructure to work out the best target given a pane or windownicm2015-12-161-2/+2
| | | | alone and use it to add pane_died and pane_exited hooks.
* Make the marked pane a cmd_find_state.nicm2015-12-151-42/+16
|
* Do lock failures slightly better, return a special value so we don'tnicm2015-11-241-4/+6
| | | | unlink the wrong thing.
* Remove the -I part of show-messages which isn't really that useful; thenicm2015-11-241-2/+2
| | | | | server start time can now be accessed with a new start_time format (use: tmux display -p '#{t:start_time}')
* Make the log stuff a bit tidier with some helper functions.nicm2015-11-241-2/+2
|
* Add getpw to pledge, makes tmux work in YP environments, discovered bynicm2015-11-221-3/+3
| | | | matthieu, ok deraadt
* Use __unused rather than rolling our own.nicm2015-11-181-2/+2
|
* Accidentally turned off pledge, turn it back on.nicm2015-11-151-2/+2
|
* Push stdout and stderr to clients more aggressively, and add an event tonicm2015-11-141-2/+2
| | | | continue if the send fails.