HP3000-L Archives

November 1996, Week 2

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Jeff Vance <[log in to unmask]>
Reply To:
Jeff Vance <[log in to unmask]>
Date:
Sat, 9 Nov 1996 22:02:30 -0800
Content-Type:
text/plain
Parts/Attachments:
text/plain (50 lines)
On Nov 9,  5:05am, Jeff Kell wrote:
> Subject: Posix stuff [was Re: Aborting users at backup time]
> Jeff Vance addressed my posix/perl example of abortjob handling with yet
> another CI file (among other follow-ups).  My point in posting the
> rather cryptic perl script was to at least "expose" some of you to a new
> way of thinking, and also to note that it exploits one of the few holes
> in the "Berlin wall <Jeanette's terminology>" between MPE and posix -
> that the "callci" facility in Posix is one of the few predictable tools
> to interact between the two.

I agree 100%, callci is a wonderful feature of the shell.  It is a great
way to get output from a CI command, script or program "into" the shell,
where it can be piped to grep awk, etc.  Callci is implemented by calling
the HPCICOMMAND intrinsic.  For those of you who have wanted the CI to be
read files more easily and to parse text more powerfully, callci is a bridge
from the CI to the shell.

snip...
> >       if lft(setvar(buf,input()),1) = '#' and &
> -> This is recent (to me) using setvar as an rvalue; most setvar on
> -> a separate line.  If the above works, a nice trick to know!  And
> -> likewise for input() as an rvalue.  I always considered these to
> -> be "statements" and not "functions returning a value".

In (I think) Release 2.1 we added the input and setvar evaluator functions.
input() and :INPUT work slightly differently when the user has no input, ie.
just hits <return>:
  :INPUT does not overwrite varname if it already exists
  input() always returns user input.
The setvar() function sets varname and returns its value.

(good line-by-line explanation of perl script snipped...)
> In conclusion I'm not necessarily pushing posix/perl/etc., but rather
> noting some concepts that I would have preferred to see in the CI to
> start with.  If he kept archives, I'm sure Jeff Vance can verify that
> I have suggested similar things before.

Yes, and Yes!

> But posix/perl can do it now,
> and it is one case of integrating posix and MPE for useful purposes.

Well said and thanks for sharing with the list!  This is an area that
needs more exposure.

Jeff Vance, CSY


--

ATOM RSS1 RSS2