aboutsummaryrefslogtreecommitdiff
path: root/cfg.c
Commit message (Collapse)AuthorAge
...
| * Rewrite of choose mode, both to simplify and tidy the code and to addnicm2017-05-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | some modern features. Now the common code is in mode-tree.c, which provides an API used by the three modes now separated into window-{buffer,client,tree}.c. Buffer mode shows buffers, client mode clients and tree mode a tree of sessions, windows and panes. Each mode has a common set of key bindings plus a few that are specific to the mode. Other changes are: - each mode has a preview pane: for buffers this is the buffer content (very useful), for others it is a preview of the pane; - items may be sorted in different ways ('O' key); - multiple items may be tagged and an operation applied to all of them (for example, to delete multiple buffers at once); - in tree mode a command may be run on the selected item (session, window, pane) or on tagged items (key ':'); - displayed items may be filtered in tree mode by using a format (this is used to implement find-window) (key 'f'); - the custom format (-F) for the display is no longer available; - shortcut keys change from 0-9, a-z, A-Z which was always a bit weird with keys used for other uses to 0-9, M-a to M-z. Now that the code is simpler, other improvements will come later. Primary key bindings for each mode are documented under the commands in the man page (choose-buffer, choose-client, choose-tree). Parts written by Thomas Adam.
* | Merge branch 'obsd-master'Thomas Adam2017-05-01
|\|
| * In order that people can use formats like #D in #() in the status linenicm2017-05-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | and not have to wait for an update when they change pane, we allow commands to run more than once a second if the expanded form changes. Unfortunately this can mean them being run far too often (pretty much continually) when multiple clients exist, because some formats (including #D) will always differ between clients. To avoid this, give each client its own tree of jobs which means that the same command will be different instances for each client - similar to how we have the tag to separate commands for different panes. GitHub issue 889; test case reported by Paul Johnson.
* | Merge branch 'obsd-master'Thomas Adam2017-04-25
|\|
| * Block the initial client if there is one until the configuration filenicm2017-04-25
| | | | | | | | has finished loading.
* | Merge branch 'obsd-master'Thomas Adam2017-04-21
|\|
| * History needs to be loaded after config parsing is done - now thatnicm2017-04-21
| | | | | | | | commands are queued, that's in cfg_done not after start_cfg finishes.
| * Do not run the config file in the context of the first client, insteadnicm2017-04-21
| | | | | | | | | | use no client like we did before. This means commands like new-session won't try to attach if they are in the config file.
* | Merge branch 'obsd-master'Thomas Adam2017-04-06
|\| | | | | | | | | | | Conflicts: server-client.c tmux.1
| * cfg_file can be static.nicm2017-04-05
| |
* | Merge branch 'obsd-master'Thomas Adam2017-02-03
|\|
| * Add a window or pane id "tag" to each format tree and use it to separatenicm2017-02-03
| | | | | | | | | | | | jobs, this means that if the same job is used for different windows or panes (for example in pane-border-format), it will be run separately for each pane.
* | Merge branch 'obsd-master'Thomas Adam2017-01-16
|\|
| * It is silly for cmd_list_parse to return an integer error when it couldnicm2017-01-15
| | | | | | | | just return NULL.
* | Merge branch 'obsd-master'Thomas Adam2017-01-09
|\|
| * Add %if/%endif for conditionals when parsing configuration files, thenicm2017-01-09
| | | | | | | | argument is a format (the new == and != are useful).
* | Merge branch 'obsd-master'Thomas Adam2017-01-09
|\|
| * Run the source-file pattern through glob(3).nicm2017-01-09
| |
* | Merge branch 'obsd-master'Thomas Adam2016-10-16
|\|
| * Mass rename struct cmd_q to struct cmdq_item and related.nicm2016-10-16
| |
* | Merge branch 'obsd-master'Thomas Adam2016-10-16
|\|
| * Rewrite command queue handling. Each client still has a command queue,nicm2016-10-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* | Merge branch 'obsd-master'Thomas Adam2016-10-14
|\|
| * source-file and some other commands can recurse back into cmdq_continue,nicm2016-10-14
| | | | | | | | | | | | | | which could potentially free the currently running command, so we need to take a reference to it in cmdq_continue_one. Fixes problem reported by Theo Buehler.
* | Merge branch 'obsd-master'Thomas Adam2016-10-12
|\| | | | | | | | | | | Conflicts: format.c osdep-openbsd.c
| * Some other stuff that can be local to one file.nicm2016-10-11
| |
| * Loads more static, except for cmd-*.c and window-*.c.nicm2016-10-10
| |
* | Merge branch 'obsd-master'Thomas Adam2016-05-12
|\|
| * - Rework load_cfg() error handling a little.tim2016-05-12
| | | | | | | | | | | | - Add -q to source-file to suppress errors about nonexistent files. Input and OK nicm@
* | Merge branch 'obsd-master'Thomas Adam2016-01-19
|\|
| * I no longer use my SourceForge address so replace it.nicm2016-01-19
| |
* | Merge branch 'obsd-master'Thomas Adam2015-11-18
|\|
| * Use __unused rather than rolling our own.nicm2015-11-18
| |
* | Merge branch 'obsd-master'Thomas Adam2015-09-09
|\|
| * No need to keep global options around for client which doesn't use them.nicm2015-09-09
| |
* | Fix includesThomas Adam2015-09-06
|/ | | | Let compat/ work out the includes; otherwise works on OpenBSD.
* Work out config file when needed not at startup.nicm2015-09-01
|
* Move initial conf load into cfg.c.nicm2015-09-01
|
* Change deref to the more sensible unref, and add a couple I missed before.nicm2015-06-05
|
* Style spacing nits.nicm2015-05-07
|
* Reset cfg_ncauses to 0 as well or we could allocate the wrong size ifnicm2015-04-27
| | | | called again.
* Fix some char* -> char *.nicm2015-04-25
|
* Use a char **,u_int pair for cfg_causes.nicm2015-04-25
|
* Rewrite of tmux mouse support which was a mess. Instead of havingnicm2015-04-19
| | | | | | | | | | | | | | | | | | | | | | | | | options for "mouse-this" and "mouse-that", mouse events may be bound as keys and there is one option "mouse" that turns on mouse support entirely (set -g mouse on). See the new MOUSE SUPPORT section of the man page for description of the key names and new flags (-t= to specify the pane or window under mouse as a target, and send-keys -M to pass through a mouse event). The default builtin bindings for the mouse are: bind -n MouseDown1Pane select-pane -t=; send-keys -M bind -n MouseDown1Status select-window -t= bind -n MouseDrag1Pane copy-mode -M bind -n MouseDrag1Border resize-pane -M To get the effect of turning mode-mouse off, do: unbind -n MouseDrag1Pane unbind -temacs-copy MouseDrag1Pane The old mouse options are now gone, set-option -q may be used to suppress warnings if mixing configuration files.
* Move cfg_causes local into cfg.c and remove struct causelist.nicm2014-10-27
|
* Handle escaped back slashes and missing new lines at end of line by usingtobias2014-06-25
| | | | | | fparseln instead of reimplementing it on our own. with input by and ok nicm@
* Remove some unnecessary includes and fix a typo.nicm2014-04-17
|
* Do not run any command line command from the client which starts thenicm2013-10-20
| | | | | | server until after the configuration file completes. This prevents it racing against run-shell or if-shell in .tmux.conf that run in the background.
* Add some additional debug logging.Nicholas Marriott2013-03-25
|
* Add a command queue to standardize and simplify commands that call otherNicholas Marriott2013-03-24
| | | | | | | | | | | | | | | | | | | | | | commands and allow a command to block execution of subsequent commands. This allows run-shell and if-shell to be synchronous which has been much requested. Each client has a default command queue and commands are consumed one at a time from it. A command may suspend execution from the queue by returning CMD_RETURN_WAIT and then resume it by calling cmd_continue() - for example run-shell does this from the callback that is fired after the job is freed. When the command queue becomes empty, command clients are automatically exited (unless attaching). A callback is also fired - this is used for nested commands in, for example, if-shell which can block execution of the client's cmdq until a new cmdq becomes empty. Also merge all the old error/info/print functions together and lose the old curclient/cmdclient distinction - a cmdq is bound to one client (or none if in the configuration file), this is a command client if c->session is NULL otherwise an attached client.