source: WorldVistAEHR/trunk/r/ZZOTHER/ZJOB1.m@ 862

Last change on this file since 862 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 2.6 KB
Line 
1ZJOB1 ;ISF/RWF - GT.M Job Exam ;06/08/2004 17:15
2 ;;8.0;KERNEL;**275**;Jul 10, 1995;Build 2
3 Q
4 ; =============
5 ; Reserved Symbols, Current Symbol Table Cleared and Replaced with Target Symbols
6 ; zz1z - Index
7 ; zz2z - Variable set syntax
8 ; zz3z - Target Job ID
9LOAD ; Load variables from target process into current partition
10 N zz1z,zz2z,zz3z,zz4z
11 s zz3z=PID
12 K (zz1z,zz2z,zz3z)
13 F zz1z=1:1 S zz2z=$G(^XUTL("XUSYS",zz3z,"JE","V",zz1z)) Q:zz2z="" D
14 . ; Overly Long Strings may not be complete...
15 . ; Better to throw away some data than to crash
16 . ; But save if you can
17 . I zz2z'["=" Q:$G(zz4z)="" S zz2z=zz4z_"="""_@zz4z_zz2z
18 . ;
19 . I zz2z["="""&($E(zz2z,$L(zz2z))'="""") S zz2z=zz2z_""""
20 . S @zz2z
21 . S zz4z=$P(zz2z,"=")
22 .Q
23 Q
24 ; =============
25 ;^XUTL("XUSYS",538971386,"JE","V",42)="ZTSK=0"
26UNIX ; gtmsendint shell script should be save in $gtm_dist
27 ; INSTALL Note:
28 ; When loading this into the $gtm_dist location, remember to
29 ; chmod 555 $gtm_dist/gtmsendint
30 ; so that the privs will be available for all.
31 ; Everything between the lines goes into gtmsendint
32 ; VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV
33 ; -------------------------------------------------------
34 ;#!/bin/tcsh -f
35 ; ## Swith the CASE construct on the number of arguments, 0, 1, or more...
36 ; switch ($#)
37 ; ## Case of NO Arguments, Interrupt everyone who runs mumps.
38 ; case 0:
39 ; foreach proc (`ps --no-headers -o pid= -C mumps`)
40 ; $gtm_dist/mupip intrpt $proc >>&/tmp/gtmsendint.$$.log
41 ; end
42 ; breaksw
43 ; ## One Argument Form to exclude the first argument (current Job $J)
44 ; ## and process everyone else and then do the current $J to signal
45 ; ## this completion of the task.
46 ; case 1:
47 ; foreach proc (`ps --no-headers -o pid= -C mumps`)
48 ; if ($proc != $1) $gtm_dist/mupip intrpt $proc >>&/tmp/gtmsendint.$$.log
49 ; end
50 ; $gtm_dist/mupip intrpt $1 >>&/tmp/gtmsendint.$$.log
51 ; breaksw
52 ; ## Else Clause
53 ; ## This list of arguments (greater than 1) is the target(s) followed by the
54 ; ## current $J of this process to signal completion of the process
55 ; default:
56 ; foreach proc ($*)
57 ; $gtm_dist/mupip intrpt $proc >>&/tmp/gtmsendint.$$.log
58 ; end
59 ; breaksw
60 ; endsw
61 ; -------------------------------------------------------
62 ; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
63VMS ; GTMSENDINT.COM DCL code should be saved in GTM$DIST
64 ;$! This is the file to process requests MUPIP INTRPT
65 ;$! Hides the MUPIP output
66 ;$ if p1 .eqs. "" then $exit
67 ;$ define sys$output NL:
68 ;$ mupip INTRPT /ID='p1'
69 ;$ if p2 .eqs. "" then goto end
70 ;$ mupip INTRPT /ID='p2'
71 ;$end:
72 ;$ deassign sys$output
73 ;$exit
Note: See TracBrowser for help on using the repository browser.