You are not logged in.
Pages: 1
I've man-db and manpages installed. Below is the output of `man gets`. You can see that this is missing many sections like BUGS and HISTORY from here https://man7.org/linux/man-pages/man3/gets.3.html. How do I have it show the full manpage?
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 char‐
acter(s).
ChannelId must be an identifier for an open channel such as the Tcl standard input
channel (stdin), the return value from an invocation of open or socket, or the result
of a channel creation command provided by a Tcl extension. The channel must have been
opened for input.
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 channelId is in non-blocking 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.
EXAMPLE
This example reads a file one line at a time and prints it out with the current line
number attached to the start of each line.
set chan [open "some.file.txt"]
set lineNumber 0
while {[gets $chan line] >= 0} {
puts "[incr lineNumber]: $line"
}
close $chan
SEE ALSO
file(n), eof(n), fblocked(n), Tcl_StandardChannels(3)
KEYWORDS
blocking, channel, end of file, end of line, line, non-blocking, read
Tcl 7.5 gets(n)Offline
You're not looking at the right man page. Try "man 3 gets" https://wiki.archlinux.org/title/Man_pa … _man_pages
Online
No luck
~ ❯ man 3 gets
No manual entry for gets in section 3I saw a guy on youtube just type `man gets` and get the same info as the website. He was on parrot os tho.
Last edited by AlwaysFinking (2024-03-08 11:59:30)
Offline
It should be there
whatis gets
pacman -Qs man-pages
pacman -Qo /usr/share/man/man3/gets.3.gzLast edited by V1del (2024-03-08 13:24:49)
Online
❯ pacman -Qs man-pages
❯ pacman -Qo /usr/share/man/man3/gets.3.gz
error: No package owns /usr/share/man/man3/gets.3.gz
❯ whatis gets
gets (n) - Read a line from a channelSmth is missing it looks like
Offline
the fact that -Qs returns nothing shows there's nothing matching that name installed.
Offline
Also note that the `man <name>` command without a specific section provided will just use the first available man page matching the name. There can be many man pages with the same name. The person on youtube you refer to gets the proper page because they have it installed. You are getting the tcl gets.n page because it may be the only gets.* man page installed (or it is at least higher priority than any others you have installed).
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
What Scimmia is saying, is that you must install the manual pages package first.
Extending Trilby’s comment, a hint: options -a, -k and -K in `man`. A meta-hint: as you can see all manual pages from Arch are available online. While it’s best to have man-pages installed locally, in general this allows you to access pages of packages not in your system. If you’re using DuckDuckGo as your search engine, it even has a dedicated bang for searching: `!archman` (and also `!aw` for searching in Arch Wiki).
Paperclips in avatars? | Sometimes I seem a bit harsh — don’t get offended too easily!
Offline
Pages: 1