Thomas Adam
8f2b5d714a
Merge branch 'obsd-master'
2020-04-13 14:01:45 +01:00
nicm
04cdd03525
Also move cmdq_item and cmdq_list into cmd-queue.c (this is to make its
...
use more clearly defined and preparation for some future work).
2020-04-13 10:59:58 +00:00
Thomas Adam
b117c3b812
Merge branch 'obsd-master'
2020-04-13 10:30:00 +01:00
nicm
c20eb0c0ae
Make struct cmd local to cmd.c and move it out of tmux.h.
2020-04-13 08:26:27 +00:00
Thomas Adam
acb2413852
Merge branch 'obsd-master'
2019-03-18 15:07:51 +00:00
nicm
10d60faba5
Store the time in the format tree rather than passing it around.
2019-03-14 23:14:27 +00:00
Thomas Adam
2c755e3c55
Merge branch 'obsd-master'
2019-03-14 22:02:39 +00:00
nicm
1416ceb575
Accept 0 time as a shorthand for now to format_expand_time.
2019-03-14 21:27:26 +00:00
Thomas Adam
1c5093c1c4
Merge branch 'obsd-master'
2018-11-30 10:02:37 +00:00
nicm
67254ed8df
Clear PANE_EXITED flag when starting new child process in case the pane
...
has been respawned.
2018-11-30 08:44:40 +00:00
Thomas Adam
efd01f3bfd
Merge branch 'obsd-master'
2018-11-19 14:02:41 +00:00
nicm
749f67b7d8
evbuffer_new and bufferevent_new can both fail (when malloc fails) and
...
return NULL. GitHub issue 1547.
2018-11-19 13:35:40 +00:00
Thomas Adam
84ddc72744
Merge branch 'obsd-master'
2018-01-17 11:26:10 +00:00
nicm
5849b73b81
Add -I to pipe-pane to connect pane stdin as well as stdout, suggested
...
by Kristof Kovacs in GitHub issue 1186.
2018-01-16 09:00:38 +00:00
Thomas Adam
acbbc93501
Merge branch 'obsd-master'
2017-07-14 22:01:10 +01:00
nicm
932f6cfbfc
Because ignore SIGCHLD early, letting signal_del restore it doesn't work
...
correctly, so set it explicitly back to default (and the others for good
measure).
2017-07-14 18:49:07 +00:00
Thomas Adam
1076a2e26c
Merge branch 'obsd-master'
...
Conflicts:
cmd-pipe-pane.c
proc.c
tmux.c
window.c
2017-07-12 13:43:08 +01:00
nicm
51112221ee
Block signals between forking and clearing signal handlers (or calling
...
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.
2017-07-12 10:04:51 +00:00
nicm
0453ad0146
Move signal code into proc.c.
2017-07-12 09:24:17 +00:00
Thomas Adam
4e01036cb6
Merge branch 'obsd-master'
2017-07-03 10:01:14 +01:00
nicm
28687f2d55
Do not close panes until process has exited and any outstanding data
...
has been written to the pipe-pane event if there is one. GitHub issue 991.
2017-07-03 08:16:03 +00:00
Thomas Adam
e354b0e40f
Merge branch 'obsd-master'
2017-05-01 14:01:14 +01:00
nicm
0ccfb61bb0
In order that people can use formats like #D in #() in the status line
...
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.
2017-05-01 12:20:55 +00:00
Thomas Adam
e802b683ea
Merge branch 'obsd-master'
2017-04-22 12:01:19 +01:00
nicm
ee45a8a149
Get rid of the extra layer of flags and cmd_prepare() and just store the
...
CMD_FIND_* flags in the cmd_entry and call it for the command. Commands
with special requirements call it themselves and update the target for
hooks to use.
2017-04-22 10:22:39 +00:00
Thomas Adam
6c333cc486
Merge branch 'obsd-master'
2017-02-03 14:01:13 +00:00
nicm
7d23d019c0
Add a window or pane id "tag" to each format tree and use it to separate
...
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.
2017-02-03 11:57:27 +00:00
Thomas Adam
1a6e696b08
Merge branch 'obsd-master'
2016-10-16 22:01:14 +01:00
nicm
b342bd0b46
Mass rename struct cmd_q to struct cmdq_item and related.
2016-10-16 19:04:05 +00:00
Thomas Adam
3d2686a236
Merge branch 'obsd-master'
2016-10-15 00:01:10 +01:00
nicm
ed971268be
Add CMD_AFTERHOOK flag to the easy commands that don't need any special handling.
2016-10-14 22:14:22 +00:00
Thomas Adam
b9dc855016
Merge branch 'obsd-master'
...
Conflicts:
format.c
osdep-openbsd.c
2016-10-12 09:45:49 +01:00
nicm
a81685bfac
Add static in cmd-* and fix a few other nits.
2016-10-10 21:51:39 +00:00
Thomas Adam
dc42c35f1f
Merge branch 'obsd-master'
2016-01-19 18:01:15 +00:00
nicm
995af0e2b7
I no longer use my SourceForge address so replace it.
2016-01-19 15:59:12 +00:00
Thomas Adam
bc6137f9e4
Merge branch 'obsd-master'
2015-12-14 01:30:15 +00:00
nicm
a3129fd4e8
Instead of combined flags for -c, -s, -t, split into different sets
...
using an enum and simplify the parsing code.
2015-12-14 00:31:54 +00:00
Thomas Adam
5caec3020d
Merge branch 'obsd-master'
2015-12-13 23:46:58 +00:00
nicm
ecfeee2e82
Use member names in cmd_entry definitions so I stop getting confused
...
about the order.
2015-12-13 21:53:57 +00:00
Thomas Adam
ae5ddfdc1a
Merge branch 'obsd-master'
2015-12-13 16:01:13 +00:00
nicm
4a4daf1303
Instead of every command resolving the target (-t or -s) itself, prepare
...
the state (client, session, winlink, pane) for it it before entering the
command. Each command provides some flags that tell the prepare step
what it is expecting.
This is a requirement for having hooks on commands (for example, if you
hook "select-window -t1:2", the hook command should to operate on window
1:2 not whatever it thinks is the current window), and should allow some
other target improvements.
The old cmd_find_* functions remain for the moment but that layer will
be dropped later.
Joint work with Thomas Adam.
2015-12-13 14:32:38 +00:00
Thomas Adam
4909a70174
Merge branch 'obsd-master'
2015-12-11 13:24:45 +00:00
nicm
01831da5f5
Add cmdq as an argument to format_create and add a format for the
...
command name (will also be used for more later).
2015-12-11 12:27:36 +00:00
Thomas Adam
af8134a6ff
Merge branch 'obsd-master'
2015-12-08 10:01:16 +00:00
nicm
e0f26dcda3
Remove format_create_flags and just pass flags to format_create.
2015-12-08 08:34:18 +00:00
Thomas Adam
7fe8edc396
Merge branch 'obsd-master'
2015-11-18 16:01:23 +00:00
nicm
577c0e3e5a
Use __unused rather than rolling our own.
2015-11-18 14:27:44 +00:00
Nicholas Marriott
cb018a4212
No paths.h on Solaris.
2015-02-06 23:24:44 +00:00
nicm
03758a50dc
Add format_expand_time and use it instead of status_replace where
...
command execution is not needed.
2015-02-06 17:11:39 +00:00
nicm
c9642ee213
Remove two unused arguments from status_replace.
2015-02-01 23:43:23 +00:00