:help :check inconsistent with :check

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

:help :check inconsistent with :check

John Little-4
I just struck an inconsistency that had me confused.

I was watching a steadily growing log file, and with autoread set, I used the command

    :check

and nothing happened (but for a message I didn't understand).  So I went to the help and ran

    :help :check

and got the help for the command I thought I was running.  Eventually I worked out that :check is actually :checkpath, and I should have used :checktime.

But surely ":h :xyz" should give the help for ":xyz", but am I missing something?

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/f9ed3ee7-06de-4960-9119-940591cee55d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: :help :check inconsistent with :check

Tony Mechelynck
On Sun, Jun 2, 2019 at 2:27 AM John Little <[hidden email]> wrote:

>
> I just struck an inconsistency that had me confused.
>
> I was watching a steadily growing log file, and with autoread set, I used the command
>
>     :check
>
> and nothing happened (but for a message I didn't understand).  So I went to the help and ran
>
>     :help :check
>
> and got the help for the command I thought I was running.  Eventually I worked out that :check is actually :checkpath, and I should have used :checktime.
>
> But surely ":h :xyz" should give the help for ":xyz", but am I missing something?

The online help has a tag for the full command (:checktime or
:checkpath) and for the _shortest_ abbreviation. Now the shortest
abbreviation for :checkpath is :che, not :check; so :help :check will
get you the first tag found which begins with :check, not necessarily
the ex-command for which :check is accepted as an abbreviation (for
this, line 827 of doc/tagsrch.txt would have had to be:
        *che* *chec* *check* *checkp* *checkpa* *checkpat* *checkpath*
instead of just the first and last ones of these; similarly for _all_
other ex-commands, which I believe would have made the doc/tags file
much bigger.

:help :check<Tab> (with 'wildmenu' on) or :help :check<Ctrl-D> would
have shown you all helptags beginning with :check, namely :checkt,
:checkpath and :checktime. It would also _not_ have shown you :check
because there is no help tag so named.

Best regards,
Tony.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/CAJkCKXvPPSB3GsJ9zY7xyi6KbNVz%3DSkBhS_vYjaU%3Dty5%3DdjXOg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: :help :check inconsistent with :check

John Little-4

On Sunday, June 2, 2019 at 1:54:53 PM UTC+12, Tony Mechelynck wrote:
> for this, line 827 of doc/tagsrch.txt would have had to be:
>         *che* *chec* *check* *checkp* *checkpa* *checkpat* *checkpath*
> instead of just the first and last ones of these; similarly for _all_
> other ex-commands, which I believe would have made the doc/tags file
> much bigger.

Extra tags would only be needed where there's ambiguity.  I compiled a list; the middle column is what you get if you type the given at the : command prompt, and the third column is the topic you get if you ask for help for the given:

given   | :            | :help :
--------+--------------+-------------
arg     | args         | arga
bre     | brewind      | break
cab     | cabbrev      | cabclear
cadd    | caddbuffer   | caddexpr
chec    | checkpath    | checktime
cne     | cnext        | cnewer
cnor    | cnoremap     | cnoreabbrev
cun     | cunmap       | cunabbrev
diff    | diffupdate   | diffget
doaut   | doautocmd    | doautoall
end     | endif        | endfunction
folddo  | folddopen    | folddoc
inor    | inoremap     | inoreabbrev
keep    | keepmarks    | keepalt
ladd    | laddbuffer   | laddexpr
lfi     | lfile        | lfirst
lge     | lgetfile     | lgetbuffer
lma     | lmap         | lmake
lock    | lockmarks    | lockvar
mkvi    | mkvimrc      | mkview
sfi     | sfind        | sfirst
snore   | snoremap     | snoremenu
ver     | version      | verbose

One or two extra tags for each of these is not going to significantly add to vim's 10,000 or so.

> :help :check<Tab> (with 'wildmenu' on) or :help :check<Ctrl-D> would
> have shown you all helptags beginning with :check

How would I have known to do that, when I did not know that there might be another command starting with "check"?  I use the help when I don't know stuff, that's the point of it.

Regards, John Little

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/ffb53d57-66be-413a-a978-20a05f48c19a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: :help :check inconsistent with :check

Tony Mechelynck
On Sun, Jun 2, 2019 at 12:48 PM John Little <[hidden email]> wrote:
> > :help :check<Tab> (with 'wildmenu' on) or :help :check<Ctrl-D> would
> > have shown you all helptags beginning with :check
>
> How would I have known to do that, when I did not know that there might be another command starting with "check"?  I use the help when I don't know stuff, that's the point of it.
>
> Regards, John Little

Well, I suppose it's a question of how we relate to encyclopaedic
sources of information. When I was a little kid, I would spend hours
with the 7-volume dictionary (7 thick folio volumes IIRC); nowadays I
can spend hours going from subject to subject by following hotlinks in
the Wikipedia — or in the Vim help; and it proves to me how true was
the remark of Socrates: «The more I know, and the more I'm conscious
of how little I know».

How would you have known, when you didn't know there was another
comand starting with :check? Well, seeing that the help didn't jibe
with what you saw, you might have wondered if there weren't another
command starting with :check, and asked for a list — if you had known
how to; though the <Tab> key is used for more than one kind of
completion, and it is very useful.

Best regards,
Tony.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/CAJkCKXsj-9xmssmp-grApFQmmD5gLYUGPy_C0_jUuj-ttpPsnQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: :help :check inconsistent with :check

Bram Moolenaar
In reply to this post by John Little-4

John Little wrote:

> I just struck an inconsistency that had me confused.
>
> I was watching a steadily growing log file, and with autoread set, I used the command
>
>     :check
>
> and nothing happened (but for a message I didn't understand).  So I went to the help and ran
>
>     :help :check
>
> and got the help for the command I thought I was running.  Eventually I worked out that :check is actually :checkpath, and I should have used :checktime.
>
> But surely ":h :xyz" should give the help for ":xyz", but am I missing something?

The tag of :checkpath is ":che", which is the shortest form.  Apparently
for ":help :check" it finds ":checkt" or ":checktime" first.
I'll add a tag for ":check" at ":checkpath", that will fix it.

--
hundred-and-one symptoms of being an internet addict:
83. Batteries in the TV remote now last for months.

 /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/201906021122.x52BMdJu003159%40masaka.moolenaar.net.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: :help :check inconsistent with :check

Bram Moolenaar
In reply to this post by John Little-4

John Little wrote:

> On Sunday, June 2, 2019 at 1:54:53 PM UTC+12, Tony Mechelynck wrote:
> > for this, line 827 of doc/tagsrch.txt would have had to be:
> >         *che* *chec* *check* *checkp* *checkpa* *checkpat* *checkpath*
> > instead of just the first and last ones of these; similarly for _all_
> > other ex-commands, which I believe would have made the doc/tags file
> > much bigger.
>
> Extra tags would only be needed where there's ambiguity.  I compiled a
> list; the middle column is what you get if you type the given at the :
> command prompt, and the third column is the topic you get if you ask
> for help for the given:

Thanks, that is very useful.  I don't know how you generated this, but I
assume these are the useful ones.

>
> given   | :            | :help :
> --------+--------------+-------------
> arg     | args         | arga
> bre     | brewind      | break
> cab     | cabbrev      | cabclear
> cadd    | caddbuffer   | caddexpr
> chec    | checkpath    | checktime
> cne     | cnext        | cnewer
> cnor    | cnoremap     | cnoreabbrev
> cun     | cunmap       | cunabbrev
> diff    | diffupdate   | diffget
> doaut   | doautocmd    | doautoall
> end     | endif        | endfunction
> folddo  | folddopen    | folddoc
> inor    | inoremap     | inoreabbrev
> keep    | keepmarks    | keepalt
> ladd    | laddbuffer   | laddexpr

This one is the wrong way around, :ladd stands for :laddexpr.

> lfi     | lfile        | lfirst
> lge     | lgetfile     | lgetbuffer
> lma     | lmap         | lmake
> lock    | lockmarks    | lockvar
> mkvi    | mkvimrc      | mkview
> sfi     | sfind        | sfirst
> snore   | snoremap     | snoremenu
> ver     | version      | verbose
>
> One or two extra tags for each of these is not going to significantly
> add to vim's 10,000 or so.
>
> > :help :check<Tab> (with 'wildmenu' on) or :help :check<Ctrl-D> would
> > have shown you all helptags beginning with :check
>
> How would I have known to do that, when I did not know that there
> might be another command starting with "check"?  I use the help when I
> don't know stuff, that's the point of it.

--
Ed's Radiator Shop: The Best Place in Town to Take a Leak.

 /// Bram Moolenaar -- [hidden email] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/201906021148.x52BmXEI007959%40masaka.moolenaar.net.
For more options, visit https://groups.google.com/d/optout.