summaryrefslogtreecommitdiffstats
path: root/tmux.c
AgeCommit message (Collapse)Author
2014-02-05Remove references to 88colour supportThomas Adam
Tmux doesn't directly support terminals with 88 colours directly anymore.
2014-01-20Merge branch 'obsd-master'Thomas
2014-01-15Do not attempt to read .tmux.conf if we can't figure out a homenicm
directory, from Tiago Cunha.
2014-01-09Three small changes from Tiago Cunha:nicm
- Check for truncation when copying path. - Don't need to use a temporary buffer in screen_set_title. - Include strerror in output when connecting to server fails.
2013-10-10We accidentally haven't been using $TMUX to work out the session for anicm
while and in fact it is less useful that using the client ttyname. So don't bother and don't pass it from the client. If we need it in future it is in c->environ.
2013-10-10Alter how tmux handles the working directory to internally use filenicm
descriptors rather than strings. - Each session still has a current working directory. - New sessions still get their working directory from the client that created them or its attached session if any. - New windows are created by default in the session working directory. - The -c flag to new, neww, splitw allows the working directory to be overridden. - The -c flag to attach let's the session working directory be changed. - The default-path option has been removed. To get the equivalent to default-path '.', do: bind c neww -c $PWD To get the equivalent of default-path '~', do: bind c neww -c ~ This also changes the client identify protocol to be a set of messages rather than one as well as some other changes that should make it easier to make backwards-compatible protocol changes in future.
2013-10-10Merge IDENTIFY_* flags with CLIENT_* flags.nicm
2013-10-10Don't treat TMUX_TMPDIR as a potential filenicm
The point of setting TMUX_TMPDIR is to then make any labels from -L go to that directory. In the case of makesocketpath() with no TMUX_TMPDIR set, would set both the path and the default socket to a file. The checking of the permissions on the file worked fine in that case, but when TMUX_TMPDIR is set, won't work on a directory. This fixes the problem by ensuring the check on the permissions is performed on directories only. By Thomas Adam.
2013-10-06We accidentally haven't been using $TMUX to work out the session for a whileNicholas Marriott
and in fact it is less useful that using the client ttyname. So don't bother and don't pass it from the client. If we need it in future it is in c->environ.
2013-10-06Alter how tmux handles the working directory to internally use file descriptorsNicholas Marriott
rather than strings. - Each session still has a current working directory. - New sessions still get their working directory from the client that created them or its attached session if any. - New windows are created by default in the session working directory. - The -c flag to new, neww, splitw allows the working directory to be overridden. - The -c flag to attach let's the session working directory be changed. - The default-path option has been removed. To get the equivalent to default-path '.', do: bind c neww -c $PWD To get the equivalent of default-path '', do: bind c neww -c '#{pane_current_path}' The equivalent of default-path '~' is left as an exercise for the reader. This also changes the client identify protocol to be a set of messages rather than one as well as some other changes that should make it easier to make backwards-compatible protocol changes in future.
2013-10-06Merge IDENTIFY_* flags with CLIENT_* flags.Nicholas Marriott
2013-10-05Fix previous not to leak fd on failure, whoops.nicm
2013-10-05Fix previous not to lead fd on failure.Nicholas Marriott
2013-10-05Use open(".")/fchdir() to save and restore current directory rather thanNicholas Marriott
getcwd()/chdir().
2013-10-05Use open(".")/fchdir() to save and restore current directory rather thannicm
getcwd()/chdir().
2013-09-30Don't treat TMUX_TMPDIR as a potential fileThomas
The point of setting TMUX_TMPDIR is to then make any labels from -L go to that directory. In the case of makesocketpath() with no TMUX_TMPDIR set, would set both the path and the default socket to a file. The checking of the permissions on the file worked fine in that case, but when TMUX_TMPDIR is set, won't work on a directory. This fixes the problem by ensuring the check on the permissions is performed on directories only.
2013-04-24Rename global configuration define.Nicholas Marriott
2013-04-24Use sysconfdir for the location of global tmux.conf (but default it to /etc),Nicholas Marriott
based on changes from Dagobert Michelsen.
2013-04-22-paths.h. Fixes Solaris, from Dagobert Michelsen.Nicholas Marriott
2013-04-14Add back missing -V flagThomas Adam
This went walkies from a previous git commit.
2013-04-13Merge branch 'obsd-master'Thomas Adam
Conflicts: tmux.c
2013-04-11Call setlocale(LC_TIME) at startup.Nicholas Marriott
2013-03-27Add TMUX_TMPDIR variable to put the socket directory outsideNicholas Marriott
TMPDIR. From Ben Boeckel.
2013-03-25Rename session idx to session id throughout and add $ prefix to targetsNicholas Marriott
to use it, extended from a diff from George Nachman.
2013-03-24Add a command queue to standardize and simplify commands that call otherNicholas Marriott
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.
2013-03-07Rename session idx to session id throughout and add $ prefix to targets to useNicholas Marriott
it, extended from a diff from George Nachman.
2013-02-23Add a command queue to standardize and simplify commands that call otherNicholas Marriott
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.
2012-11-27Merge branch 'obsd-master'Thomas Adam
Sync from OpenBSD.
2012-11-27Correctly aggregate together errors from nested config files (withNicholas Marriott
source-file). Fix by Thomas Adam, reported by Sam Livingstone-Gray
2012-11-26Call realpath earlier on the socket directory path rather than on theNicholas Marriott
socket file path because the latter may not exist yet and in that case realpath is allowed to fail. From Romain Francoise.
2012-07-11Sync OpenBSD patchset 1150:Tiago Cunha
xfree is not particularly helpful, remove it. From Thomas Adam.
2012-07-10xfree is not particularly helpful, remove it. From Thomas Adam.Nicholas Marriott
2012-06-18Sync OpenBSD patchset 1138:Tiago Cunha
Add a skeleton mode to tmux (called "control mode") that let's tmux commands be sent and output received on stdout. This can be used to integrate with other terminal emulators and should allow some other things to be made simpler later. More to come so doesn't do much yet and deliberately not documented.
2012-06-18Add a skeleton mode to tmux (called "control mode") that let's tmuxNicholas Marriott
commands be sent and output received on stdout. This can be used to integrate with other terminal emulators and should allow some other things to be made simpler later. More to come so doesn't do much yet and deliberately not documented.
2012-05-30Do not use stderr for log file and don't call log_close when not needed.Nicholas Marriott
2012-05-30Do not use stderr for log file and don't call log_close when not needed.Nicholas Marriott
2012-05-30Sync OpenBSD patchset 1123:Tiago Cunha
Simplify logging and just fprintf(stderr, ...) for early errors.
2012-05-25Simplify logging and just fprintf(stderr, ...) for early errors.Nicholas Marriott
2012-01-21Sync OpenBSD patchset 1007:Tiago Cunha
Drop the ability to have a list of keys in the prefix in favour of two separate options, prefix and prefix2. This simplifies the code and gets rid the data options type which was only used for this one option. Also add a -2 flag to send-prefix to send the secondary prefix key, fixing a cause of minor irritation. People who want three prefix keys are out of luck :-).
2012-01-21Drop the ability to have a list of keys in the prefix in favour of twoNicholas Marriott
separate options, prefix and prefix2. This simplifies the code and gets rid the data options type which was only used for this one option. Also add a -2 flag to send-prefix to send the secondary prefix key, fixing a cause of minor irritation. People who want three prefix keys are out of luck :-).
2011-10-23Sync OpenBSD patchset 968:Tiago Cunha
Try to resolve relative paths for loadb and saveb (first using client working directory if any then default-path or session wd).
2011-10-23Sync OpenBSD patchset 966:Tiago Cunha
Ignore LC_ALL and LC_CTYPE if they are empty as well as unset.
2011-10-23Try to resolve relative paths for loadb and saveb (first using clientNicholas Marriott
working directory if any then default-path or session wd).
2011-10-23Ignore LC_ALL and LC_CTYPE if they are empty as well as unset.Nicholas Marriott
2011-10-02Sync OpenBSD patchset 960:Tiago Cunha
Reject $SHELL if it is not a full path.
2011-09-25Reject $SHELL if it is not a full path.Nicholas Marriott
2011-07-09Expand the Id keyword. Tiago Cunha
2011-03-04Two fixes by Micah Cowan: make mouse work properly beyond >127 on signedNicholas Marriott
char architectures and properly parse $TMUX by stopping the socket path at the first comma.
2011-03-04Fix sscanf that was guaranteed to always fail.Micah Cowan
2011-02-14Sync OpenBSD patchset 848:Tiago Cunha
Set $TMUX without the session when background jobs are run.