help-texinfo
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [help-texinfo] Standalone info as a generic info processor?


From: Alejandro Sanchez
Subject: Re: [help-texinfo] Standalone info as a generic info processor?
Date: Mon, 7 Nov 2016 11:57:43 +0100

Thank you everyone, your answers have been of great help.

>>> The node names and line numbers are present in the "virtual index", so
>>> it should be sufficient for your needs.
>> Any way of accessing this virtual index?
> 
> At present, not from the command-line: only with the "I" command as mentioned.
> 
> I suggest we add a new option so you could do, e.g. "info -f bash
> --virtual-index for -o -" and get the list of matching index entries
> printed. Do you think that would be a good idea?
Yes, that sounds exactly like what I need. The output could be a series of 
lines with format

        %file %node %line  Description goes here

This could easily be parsed into whatever structure the client wants (e.g. a 
URI in my case). Can the Texinfo team do that or should I get my own hands 
dirty? I don’t know my way around the Texinfo codebase, so if it one of you can 
do it they would be faster and more efficient at it, but if no one wants to I 
guess I could look into it.

I could also use a “search” option like

        info -f bash --search bourne -o -

which would list the lines containing “bourne” as

        %file %node %line  The contents of the line go here

and a “menu” option like

        finfo -f bash -n 'what is bash’ --menu -o -

Which would list menu entries as

        %file %node  Name of the menu item

But if those two are too much work I could imitate them in Vim. My goal is to 
reach feature-parity with standalone info. The features don’t have to be 
accessible in the same way (e.g. Space and Backspace for scrolling), but users 
should have an equivalent analog for each one.

>> 
>>> Also, I think you misunderstand the structure of an Info file. Nodes
>>> are not nested within one another, so your location would just be
>>> 
>>> info://file-name/node-2/
>> I see. The version of info that came with my system (4.8) required me to go 
>> from node to node as if they were nested, but 6.3 doesn’t.
> 
> The nodes are not nested within one another. But the nodes contain
> menus which refer to other nodes, so the nodes form a tree structure
> within the info file.
I understand. I have redesigned my plugin to respect that.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]