Unix and Linux Discussions Tagged with end |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
2 |
6,568 |
UNIX for Beginners Questions & Answers |
|
|
|
16 |
13,572 |
UNIX for Beginners Questions & Answers |
|
|
|
5 |
7,056 |
UNIX for Beginners Questions & Answers |
|
|
|
10 |
12,541 |
AIX |
|
|
|
2 |
3,113 |
Shell Programming and Scripting |
|
|
|
10 |
5,423 |
Shell Programming and Scripting |
|
|
|
4 |
3,184 |
Shell Programming and Scripting |
|
|
|
9 |
2,026 |
Shell Programming and Scripting |
|
|
|
5 |
2,736 |
Shell Programming and Scripting |
|
|
|
6 |
2,958 |
Shell Programming and Scripting |
|
|
|
0 |
1,131 |
Security Advisories (RSS) |
|
|
|
0 |
2,022 |
Cartoons for Geeks |
|
|
|
0 |
1,746 |
Complex Event Processing RSS News |
|
|
|
3 |
18,570 |
Shell Programming and Scripting |
|
|
|
5 |
18,923 |
Solaris |
|
|
|
0 |
1,324 |
UNIX and Linux RSS News |
|
|
|
0 |
1,365 |
UNIX and Linux RSS News |
|
|
|
9 |
55,207 |
UNIX for Dummies Questions & Answers |
|
|
|
14 |
7,998 |
UNIX for Dummies Questions & Answers |
|
|
|
12 |
30,403 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
16,087 |
UNIX for Advanced & Expert Users |
|
|
|
4 |
116,745 |
Shell Programming and Scripting |
|
|
|
4 |
28,918 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
72,565 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
4,254 |
UNIX for Advanced & Expert Users |
|
|
|
1 |
4,280 |
Programming |
|
|
|
3 |
13,000 |
Shell Programming and Scripting |
|
|
|
4 |
6,546 |
UNIX for Advanced & Expert Users |
|
|
|
1 |
3,477 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
3,675 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
8,283 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
3,888 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
4,983 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
3,470 |
Programming |
|
|
|
2 |
3,929 |
Programming |
|
|
|
5 |
15,162 |
UNIX for Advanced & Expert Users |
|
|
|
2 |
9,484 |
UNIX for Advanced & Expert Users |
|
|
|
7 |
7,036 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
3,359 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
12,116 |
UNIX for Dummies Questions & Answers |
gets(n) Tcl Built-In Commands gets(n)
__________________________________________________________________________________________________________________________________________________
NAME
gets - Read a line from a channel
SYNOPSIS
gets channelId ?varName?
_________________________________________________________________
DESCRIPTION
This command reads the next line from channelId, returns everything in the line up to (but not including) the end-of-line character(s), and
discards the end-of-line character(s). If varName is omitted the line is returned as the result of the command. If varName is specified
then the line is placed in the variable by that name and the return value is a count of the number of characters returned.
If end of file occurs while scanning for an end of line, the command returns whatever input is available up to the end of file. If chan-
nelId is in nonblocking mode and there is not a full line of input available, the command returns an empty string and does not consume any
input. If varName is specified and an empty string is returned in varName because of end-of-file or because of insufficient data in non-
blocking mode, then the return count is -1. Note that if varName is not specified then the end-of-file and no-full-line-available cases
can produce the same results as if there were an input line consisting only of the end-of-line character(s). The eof and fblocked commands
can be used to distinguish these three cases.
SEE ALSO
file(n), eof(n), fblocked(n)
KEYWORDS
blocking, channel, end of file, end of line, line, nonblocking, read
Tcl 7.5 gets(n)