I'm trying to use the following script,
#!/bin/sh
!!:s/lpadm/give/ $1

The problem i'm having is accessing the history, i know that this script 
opens its own shell and references that history, which is why i get a 
0:event not found error. What I want to do is reference the history of the 
current shell, i.e the one in which i run the script.
Basically it is setup so, you look at a printing account, ie lpadm issjlk, 
then you type the script name followed by the number of credits, ie, gi 30. 
this then gives username issjlk (from the previous command (!!) 30 credits.

Any suggestions ??
I am going to do a script that does both lpadm and then the give commands so 
need for a history command, but it would be useful to know if i can do it 
the way i wanted to above.

Jamie

_____________________________________________________________________________________
Get more from the Web.  FREE MSN Explorer download : http://explorer.msn.com


Reply via email to