🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
7 messages
7 total messages Started by Troy Piggins Fri, 16 Feb 2007 04:07
[slrn] reading manuals from within slrn macro
#195652
Author: Troy Piggins
Date: Fri, 16 Feb 2007 04:07
37 lines
2206 bytes
A simple macro to view slrns manuals, man pages, or any other
reference docs you like from within slrn via a menu.

Simply hit "F1" to bring up the menu, pick the doc you want, then
hit enter.  To escape out of the menu, slrn standard thing to do
is hit ctrl-g.

#v+

define view_manuals() {

% be sure to check the path to your slrn docs with trailing "/"
% default is /usr/local/share/doc/slrn/

  variable docpath="/usr/local/share/doc/slrn/";

  variable man=select_list_box( "slrn Docs", "manpage", "manual", 
    "score", "slrnfuns", 4, 1);

  switch (man)
    { case "manpage" : system( "man slrn");}
    { case "manual" : system( "less "+docpath+"manual.txt");}
    { case "score" : system( "less "+docpath+"score.txt");}
    { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
    { message ("Error in doc selection");}

}
definekey ( "view_manuals", "<f1>", "article");
definekey ( "view_manuals", "<f1>", "group");

#v-

-- 
Troy Piggins             ,-O   (o-    O         All your sigs are belong to us.
http://piggo.com/~troy  O   )  //\     O
RLU#415538               `-O   V_/_  OOO
hackerkey://v3sw5HPUhw5ln4pr6OSck1ma9u6LwXm5l6Di2e6t5MGSRb8OTen4g7OPa3Xs7MIr8p7
Re: [slrn] reading manuals from within slrn macro
#195656
Author: Blinky the Shark
Date: Fri, 16 Feb 2007 08:06
39 lines
2343 bytes
Troy Piggins wrote:
> A simple macro to view slrns manuals, man pages, or any other
> reference docs you like from within slrn via a menu.
>
> Simply hit "F1" to bring up the menu, pick the doc you want, then
> hit enter.  To escape out of the menu, slrn standard thing to do
> is hit ctrl-g.
>
> #v+
>
> define view_manuals() {
>
> % be sure to check the path to your slrn docs with trailing "/"
> % default is /usr/local/share/doc/slrn/
>
>   variable docpath="/usr/local/share/doc/slrn/";
>
>   variable man=select_list_box( "slrn Docs", "manpage", "manual", 
>     "score", "slrnfuns", 4, 1);
>
>   switch (man)
>     { case "manpage" : system( "man slrn");}
>     { case "manual" : system( "less "+docpath+"manual.txt");}
>     { case "score" : system( "less "+docpath+"score.txt");}
>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>     { message ("Error in doc selection");}
>
> }
> definekey ( "view_manuals", "<f1>", "article");
> definekey ( "view_manuals", "<f1>", "group");
>
> #v-

Yeah?  What do you do with that code?  ;)

-- 
Blinky                                                   RLU 297263 
Killing all posts from Google Groups
The Usenet Improvement Project: http://blinkynet.net/comp/uip5.html
Re: [slrn] reading manuals from within slrn macro
#195657
Author: Troy Piggins
Date: Fri, 16 Feb 2007 08:23
23 lines
1938 bytes
* Blinky the Shark is quoted & my replies are inline below :
> Troy Piggins wrote:
> [---=| Quote block shrinked by t-prot: 21 lines snipped |=---]
>>     { case "manual" : system( "less "+docpath+"manual.txt");}
>>     { case "score" : system( "less "+docpath+"score.txt");}
>>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>>     { message ("Error in doc selection");}
>>
>> }
>> definekey ( "view_manuals", "<f1>", "article");
>> definekey ( "view_manuals", "<f1>", "group");
>>
>> #v-
>
> Yeah?  What do you do with that code?  ;)

YYYAAAAAAAHHHH!!!! </hair gone>

-- 
Troy Piggins             ,-O   (o-    O         All your sigs are belong to us.
http://piggo.com/~troy  O   )  //\     O
RLU#415538               `-O   V_/_  OOO
hackerkey://v3sw5HPUhw5ln4pr6OSck1ma9u6LwXm5l6Di2e6t5MGSRb8OTen4g7OPa3Xs7MIr8p7
Re: [slrn] reading manuals from within slrn macro
#195658
Author: Blinky the Shark
Date: Fri, 16 Feb 2007 08:36
26 lines
1952 bytes
Troy Piggins wrote:
> * Blinky the Shark is quoted & my replies are inline below :
>> Troy Piggins wrote:
>> [---=| Quote block shrinked by t-prot: 21 lines snipped |=---]
>>>     { case "manual" : system( "less "+docpath+"manual.txt");}
>>>     { case "score" : system( "less "+docpath+"score.txt");}
>>>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>>>     { message ("Error in doc selection");}
>>>
>>> }
>>> definekey ( "view_manuals", "<f1>", "article");
>>> definekey ( "view_manuals", "<f1>", "group");
>>>
>>> #v-
>>
>> Yeah?  What do you do with that code?  ;)
>
> YYYAAAAAAAHHHH!!!! </hair gone>

:)


-- 
Blinky                                                   RLU 297263 
Killing all posts from Google Groups
The Usenet Improvement Project: http://blinkynet.net/comp/uip5.html
Re: [slrn] reading manuals from within slrn macro
#195661
Author: SINNER
Date: Fri, 16 Feb 2007 13:51
46 lines
2837 bytes
* Troy Piggins wrote in news.software.readers:
> A simple macro to view slrns manuals, man pages, or any other
> reference docs you like from within slrn via a menu.

> Simply hit "F1" to bring up the menu, pick the doc you want, then
> hit enter.  To escape out of the menu, slrn standard thing to do
> is hit ctrl-g.

> #v+

> define view_manuals() {

> % be sure to check the path to your slrn docs with trailing "/"
> % default is /usr/local/share/doc/slrn/

>   variable docpath="/usr/local/share/doc/slrn/";

>   variable man=select_list_box( "slrn Docs", "manpage", "manual", 
>     "score", "slrnfuns", 4, 1);

>   switch (man)
>     { case "manpage" : system( "man slrn");}
>     { case "manual" : system( "less "+docpath+"manual.txt");}
>     { case "score" : system( "less "+docpath+"score.txt");}
>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>     { message ("Error in doc selection");}

> }
> definekey ( "view_manuals", "<f1>", "article");
> definekey ( "view_manuals", "<f1>", "group");

> #v-

Troy, Do you use gnome-terminal?

F1 brings up the Gnome help browser, so I had to change it to F2. Also,
I know you use Ubuntu and the docs in the slrn package are gzipped so I
had to add the .gz to the above 3 txt files. Beyond that, AWESOME.
Thanks for doing all the heavy lifting :)

I would go so far as to say you might consider sending them in to be
posted on the macros page, both this and the mutt one. Very nice stuff.

-- 
David
 All generalisations are dangerous, including this one.
Re: [slrn] reading manuals from within slrn macro
#195677
Author: Troy Piggins
Date: Fri, 16 Feb 2007 23:24
65 lines
3369 bytes
* SINNER is quoted & my replies are inline below :
> * Troy Piggins wrote in news.software.readers:
>> A simple macro to view slrns manuals, man pages, or any other
>> reference docs you like from within slrn via a menu.
>
>> Simply hit "F1" to bring up the menu, pick the doc you want, then
>> hit enter.  To escape out of the menu, slrn standard thing to do
>> is hit ctrl-g.
>
>> #v+
>
>> define view_manuals() {
>
>> % be sure to check the path to your slrn docs with trailing "/"
>> % default is /usr/local/share/doc/slrn/
>
>>   variable docpath="/usr/local/share/doc/slrn/";
>
>>   variable man=select_list_box( "slrn Docs", "manpage", "manual", 
>>     "score", "slrnfuns", 4, 1);
>
>>   switch (man)
>>     { case "manpage" : system( "man slrn");}
>>     { case "manual" : system( "less "+docpath+"manual.txt");}
>>     { case "score" : system( "less "+docpath+"score.txt");}
>>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>>     { message ("Error in doc selection");}
>
>> }
>> definekey ( "view_manuals", "<f1>", "article");
>> definekey ( "view_manuals", "<f1>", "group");
>
>> #v-
>
> Troy, Do you use gnome-terminal?

No.  Mostly I log in from my WinXP machine over ssh via PuTTY to
my Ubuntu machine.

> F1 brings up the Gnome help browser, so I had to change it to F2. Also,

Ok.  Of course any key will do it.

> I know you use Ubuntu and the docs in the slrn package are gzipped so I
> had to add the .gz to the above 3 txt files. Beyond that, AWESOME.

Aah.  Ok.  I don't use the slrn Ubuntu package, I compile slrn
from source because I use a patched version (score colour patch).

> Thanks for doing all the heavy lifting :)

It aint all /that/ heavy  ;)

> I would go so far as to say you might consider sending them in to be
> posted on the macros page, both this and the mutt one. Very nice stuff.

Will do.  Thanks.  The code in them isn't that "pretty" - I am no
programmer.  But they work for me, and hopefully others find them
useful.

-- 
Troy Piggins             ,-O   (o-    O         All your sigs are belong to us.
http://piggo.com/~troy  O   )  //\     O
RLU#415538               `-O   V_/_  OOO
hackerkey://v3sw5HPUhw5ln4pr6OSck1ma9u6LwXm5l6Di2e6t5MGSRb8OTen4g7OPa3Xs7MIr8p7
Re: [slrn] reading manuals from within slrn macro
#205021
Author: Will Parsons
Date: Tue, 28 Aug 2007 23:19
40 lines
2147 bytes
Troy Piggins wrote:
> A simple macro to view slrns manuals, man pages, or any other
> reference docs you like from within slrn via a menu.
>
> Simply hit "F1" to bring up the menu, pick the doc you want, then
> hit enter.  To escape out of the menu, slrn standard thing to do
> is hit ctrl-g.
>
> #v+
>
> define view_manuals() {
>
> % be sure to check the path to your slrn docs with trailing "/"
> % default is /usr/local/share/doc/slrn/
>
>   variable docpath="/usr/local/share/doc/slrn/";
>
>   variable man=select_list_box( "slrn Docs", "manpage", "manual", 
>     "score", "slrnfuns", 4, 1);
>
>   switch (man)
>     { case "manpage" : system( "man slrn");}
>     { case "manual" : system( "less "+docpath+"manual.txt");}
>     { case "score" : system( "less "+docpath+"score.txt");}
>     { case "slrnfuns" : system( "less "+docpath+"slrnfuns.txt");}
>     { message ("Error in doc selection");}
>
> }
> definekey ( "view_manuals", "<f1>", "article");
> definekey ( "view_manuals", "<f1>", "group");
>
> #v-

(Responding to an old post...)

This is really good!  Thanks - this is much better than hunting around the
file system trying to remember where the documenation is!

-- 
Will P.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads