📄 talk.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><html><head><!-- Copyright 1997 The Open Group, All Rights Reserved --><title>talk</title></head><body bgcolor=white><center><font size=2>The Single UNIX ® Specification, Version 2<br>Copyright © 1997 The Open Group</font></center><hr size=2 noshade><h4><a name = "tag_001_014_2201"> </a>NAME</h4><blockquote>talk - talk to another user</blockquote><h4><a name = "tag_001_014_2202"> </a>SYNOPSIS</h4><blockquote><pre><code>talk <i>address </i><b>[</b><i>terminal</i><b>]</b></code></pre></blockquote><h4><a name = "tag_001_014_2203"> </a>DESCRIPTION</h4><blockquote>The<i>talk</i>utility is a two-way, screen-oriented communication program.<p>When first invoked,<i>talk</i>sends a message similar to:<pre><code>Message from <i><unspecified string></i>talk: connection requested by <i>your_address</i>talk: respond with: talk <i>your_address</i></code></pre>to the specified<i>address</i>.At this point, the recipientof the message can reply by typing:<pre><code>talk <i>your_address</i></code></pre><p>Once communication is established, the two parties can typesimultaneously, with their outputdisplayed in separate regionsof the screen.Characters are processed as follows:<ul><p><li>Typing thealertcharacter will alertthe recipient's terminal.<p><li>Typing<control>-Lwill cause the sender'sscreen regions to be refreshed.<p><li>Typing the erase and killcharacters will affect the sender's terminalin the manner described by the<b>termios</b>interface inthe <b>XBD</b> specification, <a href="../xbd/termios.html"><b>General Terminal Interface</b> </a> .<p><li>Typing the interrupt or end-of-file characters will terminate the local<i>talk</i>utility.Once the<i>talk</i>session has been terminated on one side, the otherside of the<i>talk</i>session will be notified that the<i>talk</i>session has been terminated and will be able to do nothing except exit.<p><li>Typing characters from LC_CTYPE classifications<b>print</b>or<b>space</b>will cause those characters to be sent to the recipient's terminal.<p><li>When and only when the<i><a href="stty.html">stty</a></i><i>iexten</i>local modeis enabled,the existence and processing ofadditional special controlcharacters andmulti-byte or single-byte functions is implementation-dependent.<p><li>Typing other non-printable characterswill cause implementation-dependent sequences ofprintable characters to be sent to the recipient's terminal.<p></ul><p>Permission tobe a recipient of a<i>talk</i>message can be denied or granted by use of the<i><a href="mesg.html">mesg</a></i>utility.However, a user's privilege may further constrainthe domain of accessibility of other users' terminals.The<i>talk</i>utilitywill fail when the user lacks the appropriate privilegesto perform the requested action.<p>Certain block-mode terminals do not have all the capabilities necessaryto support the simultaneous exchange of messages required for<i>talk</i>.When this type of exchange cannot be supported on such terminals, theimplementation may support an exchange with reduced levels ofsimultaneous interaction or it may report an error describing theterminal-related deficiency.</blockquote><h4><a name = "tag_001_014_2204"> </a>OPTIONS</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2205"> </a>OPERANDS</h4><blockquote>The following operands are supported:<dl compact><dt><i>address</i><dd>The recipient of the<i>talk</i>session.One form of<i>address</i>is the<<i>user name</i>>,as returned by the<i><a href="who.html">who</a></i>utility.Other address formats and how they are handled are unspecified.<dt><i>terminal</i><dd>If the recipient is logged in more than once, the<i>terminal</i>argument can be used to indicate the appropriate terminal name.If<i>terminal</i>is not specified, the<i>talk</i>message will be displayed on one or more accessible terminalsin use by the recipient.The format of<i>terminal</i>will be the same as that returned by the<i><a href="who.html">who</a></i>utility.</dl></blockquote><h4><a name = "tag_001_014_2206"> </a>STDIN</h4><blockquote>Characters read from standard input will be copied to therecipient's terminal in an unspecified manner.If standard input is not a terminal, talk will write a diagnosticmessage and exit with a non-zero status.</blockquote><h4><a name = "tag_001_014_2207"> </a>INPUT FILES</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2208"> </a>ENVIRONMENT VARIABLES</h4><blockquote>The following environment variables affect the execution of<i>talk</i>:<dl compact><dt><i>LANG</i><dd>Provide a default value for the internationalisation variablesthat are unset or null.If<i>LANG</i>is unset or null, the corresponding value from theimplementation-dependent default locale will be used.If any of the internationalisation variables contains an invalid setting, theutility will behave as if none of the variables had been defined.<dt><i>LC_ALL</i><dd>If set to a non-empty string value,override the values of all the other internationalisation variables.<dt><i>LC_CTYPE</i><dd>Determine thelocale for the interpretation of sequences of bytes of text data ascharacters (for example, single- as opposed to multi-byte charactersin arguments and input files).If the recipient's locale does not use an LC_CTYPE equivalentto the sender's, the results are undefined.<dt><i>LC_MESSAGES</i><dd>Determine the locale that should be used to affectthe format and contents of diagnosticmessages written to standard errorand informative messages written to standard output.<dt><i>NLSPATH</i><dd>Determine the location of message cataloguesfor the processing of<i>LC_MESSAGES .</i><dt><i>TERM</i><dd>Determinethe name of the invoker's terminal type.If this variable isunset or null, an unspecified default terminal type will be used.</dl></blockquote><h4><a name = "tag_001_014_2209"> </a>ASYNCHRONOUS EVENTS</h4><blockquote>When the<i>talk</i>utility receives a SIGINT signal,the utility will terminate and exit with a zero status.It will take the standard action for all other signals.</blockquote><h4><a name = "tag_001_014_2210"> </a>STDOUT</h4><blockquote>If standard output is a terminal,characters copied from the recipient's standard inputmay be written to standard output.Standard output also may be used for diagnostic messages.If standard output is not a terminal,<i>talk</i>will exit with a non-zero status.</blockquote><h4><a name = "tag_001_014_2211"> </a>STDERR</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2212"> </a>OUTPUT FILES</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2213"> </a>EXTENDED DESCRIPTION</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2214"> </a>EXIT STATUS</h4><blockquote>The following exit values are returned:<dl compact><dt>0<dd>Successful completion.<dt>>0<dd>An error occurred or<i>talk</i>was invoked on a terminal incapable of supporting it.</dl></blockquote><h4><a name = "tag_001_014_2215"> </a>CONSEQUENCES OF ERRORS</h4><blockquote>Default.</blockquote><h4><a name = "tag_001_014_2216"> </a>APPLICATION USAGE</h4><blockquote>Because the handling of non-printable, non-space charactersis tied to the<i><a href="stty.html">stty</a></i>description of<i>iexten</i>,implementation extensions within the terminal drivercan be accessed.For example, some implementations provide line editingfunctions with certain control character sequences.</blockquote><h4><a name = "tag_001_014_2217"> </a>EXAMPLES</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2218"> </a>FUTURE DIRECTIONS</h4><blockquote>None.</blockquote><h4><a name = "tag_001_014_2219"> </a>SEE ALSO</h4><blockquote><i><a href="mesg.html">mesg</a></i>,<i><a href="who.html">who</a></i>,<i><a href="write.html">write</a></i>,the <b>XBD</b> specification, <a href="../xbd/termios.html"><b>General Terminal Interface</b> </a> .</blockquote><hr size=2 noshade><center><font size=2>UNIX ® is a registered Trademark of The Open Group.<br>Copyright © 1997 The Open Group<br> [ <a href="../index.html">Main Index</a> | <a href="../xshix.html">XSH</a> | <a href="../xcuix.html">XCU</a> | <a href="../xbdix.html">XBD</a> | <a href="../cursesix.html">XCURSES</a> | <a href="../xnsix.html">XNS</a> ]</font></center><hr size=2 noshade></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -