El 09/02/2013, a les 2:21, Johnny Billquist <bqt at softjar.se> va escriure:
<fs($(<a href="hecnetinfo.com?q=$;.UAS)$-CQA,.XAI">$GAI</a>$>EX$$
Clear as a spring rain.
Shouldn't this end in "CARRIER LOST"? :)
Jordi Guillaumes i Pons
jg at jordi.guillaumes.name
HECnet: BITXOV::JGUILLAUMES
That's pretty nifty - but I realised that with a bit of python I can strip out the stuff that isn't really of interest to people such as the interface and next node etc.
Thanks for the help though, TECO still looks like modem line noise to me..:)
sampsa
On 9 Feb 2013, at 03:21, Johnny Billquist <bqt at softjar.se> wrote:
On 2013-02-09 02:06, Sampsa Laine wrote:
Crap, just realised this won't work, I need to duplicate the strings i.e. one for the href, one for the actual text.
I'm just gonna write a little python script to do it..
This is what I was wondering already initially, hence my question about if you didn't want a little more than just the <a> for the tag...
Anyway, TECO to the rescue...
Hold on to your hat. Were we go. A complete TECO program for this. Replace all dollar signs with ESCAPE.
<fs($(<a href="hecnetinfo.com?q=$;.UAS)$-CQA,.XAI">$GAI</a>$>EX$$
Clear as a spring rain.
Let me know if you want me to explain it... ;-)
Johnny
--
Johnny Billquist || "I'm on a bus
|| on a psychedelic trip
email: bqt at softjar.se || Reading murder books
pdp is alive! || tryin' to stay hip" - B. Idol
On 2013-02-09 02:06, Sampsa Laine wrote:
Crap, just realised this won't work, I need to duplicate the strings i.e. one for the href, one for the actual text.
I'm just gonna write a little python script to do it..
This is what I was wondering already initially, hence my question about if you didn't want a little more than just the <a> for the tag...
Anyway, TECO to the rescue...
Hold on to your hat. Were we go. A complete TECO program for this. Replace all dollar signs with ESCAPE.
<fs($(<a href="hecnetinfo.com?q=$;.UAS)$-CQA,.XAI">$GAI</a>$>EX$$
Clear as a spring rain.
Let me know if you want me to explain it... ;-)
Johnny
--
Johnny Billquist || "I'm on a bus
|| on a psychedelic trip
email: bqt at softjar.se || Reading murder books
pdp is alive! || tryin' to stay hip" - B. Idol
Crap, just realised this won't work, I need to duplicate the strings i.e. one for the href, one for the actual text.
I'm just gonna write a little python script to do it..
smapsa
On 9 Feb 2013, at 02:56, Jordi Guillaumes i Pons <jg at jordi.guillaumes.name> wrote:
El 09/02/2013, a les 1:53, Sampsa Laine <sampsa at mac.com> va escriure:
Actually, it'd be useful to drop both the parenthesis (i.e. "(" and ")") so I can prepend the proper href for the "(", I am totally out of my depth here, could you tell me what to change in the EDITCMD.EDT
Could you give me a sample of how do you want the line to be?
59.60 <a href="hecnetinfo.com?q=R29GWA"</a> EIA-0 8.400 <a href="hecnetinfo.com?q=R29GWA"GORVAX</a>
El 09/02/2013, a les 1:53, Sampsa Laine <sampsa at mac.com> va escriure:
Actually, it'd be useful to drop both the parenthesis (i.e. "(" and ")") so I can prepend the proper href for the "(", I am totally out of my depth here, could you tell me what to change in the EDITCMD.EDT
Could you give me a sample of how do you want the line to be?
BTW it is really simple. The syntax is:
SUBST /before/after/ WHOLE
If "before" or "after" contain "/" then you must use another string separator, hence:
SUBST @before at after@ WHOLE
Jordi Guillaumes i Pons
jg at jordi.guillaumes.name
HECnet: BITXOV::JGUILLAUMES
Actually, it'd be useful to drop both the parenthesis (i.e. "(" and ")") so I can prepend the proper href for the "(", I am totally out of my depth here, could you tell me what to change in the EDITCMD.EDT
sampsa
On 9 Feb 2013, at 02:42, Jordi Guillaumes i Pons <jg at jordi.guillaumes.name> wrote:
Hmmmm... Try this, is really a 100% VMS way of doing it:
$ TYPE EDITCMD.EDT
SUBST /(/<a>(/ WHOLE
SUBST @)@)</a>@ WHOLE
EXIT
$ edit/edt/command=editcmd.edt/output=barfoo.dat foobar.dat
.
.
.
.
.
.
424 62.4 <a>(COPOKA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
425 62.5 <a>(BOPOHA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
426 62.6 <a>(KOPOBA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
427 62.637 <a>(CTAKAH)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
Is that what you want?
El 09/02/2013, a les 1:36, Sampsa Laine <sampsa at mac.com> va escriure:
Actually, it's a bit stupid to call SHOW KNOW NODES on EVERY invocation, it's not like the data changes all THAT often. So I'm going to build a little DCL script to do this say every day and then just list the output of that instead of doing SHOW KNOWN NODES...
sampsa
Jordi Guillaumes i Pons
jg at jordi.guillaumes.name
HECnet: BITXOV::JGUILLAUMES
Hmmmm... Try this, is really a 100% VMS way of doing it:
$ TYPE EDITCMD.EDT
SUBST /(/<a>(/ WHOLE
SUBST @)@)</a>@ WHOLE
EXIT
$ edit/edt/command=editcmd.edt/output=barfoo.dat foobar.dat
.
.
.
.
.
.
424 62.4 <a>(COPOKA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
425 62.5 <a>(BOPOHA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
426 62.6 <a>(KOPOBA)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
427 62.637 <a>(CTAKAH)</a> TCP-0-0 8.400 <a>(GO
RVAX)</a>
Is that what you want?
El 09/02/2013, a les 1:36, Sampsa Laine <sampsa at mac.com> va escriure:
Actually, it's a bit stupid to call SHOW KNOW NODES on EVERY invocation, it's not like the data changes all THAT often. So I'm going to build a little DCL script to do this say every day and then just list the output of that instead of doing SHOW KNOWN NODES...
sampsa
Jordi Guillaumes i Pons
jg at jordi.guillaumes.name
HECnet: BITXOV::JGUILLAUMES
Actually, it's a bit stupid to call SHOW KNOW NODES on EVERY invocation, it's not like the data changes all THAT often. So I'm going to build a little DCL script to do this say every day and then just list the output of that instead of doing SHOW KNOWN NODES...
sampsa
On 9 Feb 2013, at 02:27, Cory Smelosky <b4 at gewt.net> wrote:
On 8 Feb 2013, at 19:23, Sampsa Laine <sampsa at mac.com> wrote:
On 9 Feb 2013, at 02:05, Johnny Billquist <bqt at softjar.se> wrote:
On 2013-02-09 00:59, Sampsa Laine wrote:
I'm thinking of tweaking the HECNET infoservice* on RHESUS, and figured it'd be nice if the nodes in the output of NCP SHOW KNOWN NODES were hyperlinks.
On Unix I would just replace all the "(" characters with an opening <a> + "(" tag and all the ")" with a closing </a> tag + ")" using sed.
What's the correct DCL way to do this?
sampsa
* This is the page I'm thinking of tweaking: http://rhesus.sampsa.com/cgi-bin/hecnetinfo/hecnetinfo.com
TECO? :-)
<FS($(<a>$FS)$</a>)$;>
But I don't think just a <a> tag would be enough, would it? Wouldn't you want a href in there, and so on?
Of course, but I left that out for the sake of brevity. How do I invoke TECO on VMS? I've only heard apocryphal tales of it's less than simple syntax, never actually used it..
I believe edit/teco should work.
So the full command would look something like:
$MCR NCP SHOW KNOWN NODES TO FOOBAR
$EDIT/TECO FOOBAR.LIST
<FS($(<a>$FS)$</a>)$;>
[...something to quit TECO goes here...]
How do I exit TECO?
sampsa