I came across a routine that ran on DSM to invoke the VMS editor and
used it to model a similar routine for Cache on Linux. It can easily be
modified to invoke any editor you wish.

Following is the code:

Cache for UNIX^INT^MY FAVORITE EDITOR^~Format=Cache.S~
%RO on 06 Aug 2004   5:27 PM
%ZEMACS^INT^1^59744,37873^
%ZEMACS ;Template for using EMACS editor on Cache' Routines ; 16 Jul
2004  7:15 AM
 ;R. Witkop, 16 Jul 2004
 ; last modified 7/28/2004
 N ROU,FIL
ASK ;
 R !,"Routine to edit: ",ROU Q:ROU=""
 I '$D(^ROUTINE(ROU)) W " (does not exist)" g ASK
 L +^ZEMACS(ROU):10 E  W "  (somebody is editing the routine)" G ASK
 S FIL=$TR(ROU,"%._","")_".TXT",$ZT="ERR"
 O FIL:"WNS" U FIL X "ZL @ROU ZP" C FIL
 I $ZF(-1,"emacs "_FIL)
 O FIL:"R" S $ZT="ERR" U FIL X "ZL  ZS @ROU"
 
ERR S $ZT="" I $ZE'="",$ZE'="<ENDOFFILE>" U 0 W !,$ZE
 C FIL:"D" I $ZF(-1,"rm -f "_FIL_"*")
 L -^ZEMACS(ROU)
 Q
 







On Thu, 2005-11-17 at 09:05, Greg Woodhouse wrote:
> I wonder if anyone has written code to invoke vi as routine editor in
> Cache (over Unix rather than Windows, of course). A comparable problem
> for VMS would be using %EDT/TPU.
> 
> 
> 
> ===
> Gregory Woodhouse  <[EMAIL PROTECTED]>
> 
> 
> "Interaction is the mind-body problem of computing."
> 
> --Philip Wadler
> 
> 
> 



-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.  Get Certified Today
Register for a JBoss Training Course.  Free Certification Exam
for All Training Attendees Through End of 2005. For more info visit:
http://ads.osdn.com/?ad_id=7628&alloc_id=16845&op=click
_______________________________________________
Hardhats-members mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/hardhats-members

Reply via email to