home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!stanford.edu!agate!spool.mu.edu!uwm.edu!cs.utexas.edu!usc!news.service.uci.edu!unogate!mvb.saic.com!vmsnet-sources
- Newsgroups: vmsnet.sources
- From: brent@uwovax.uwo.ca (Brent Sterner)
- Subject: NOTICE for VMS, part 01/01
- Organization: University of Western Ont, London
- Date: Thu, 05 Nov 1992 18:44:33 GMT
- Message-ID: <8998937@MVB.SAIC.COM>
- Lines: 763
- Approved: Mark.Berryman@Mvb.Saic.Com
-
- Submitted-by: brent@uwovax.uwo.ca (Brent Sterner)
- Posting-number: Volume 3, Issue 241
- Archive-name: notice/part01
-
- $! ------------------ CUT HERE -----------------------
- $ v='f$verify(f$trnlnm("SHARE_UNPACK_VERIFY"))'
- $!
- $! This archive created by VMS_SHARE Version 8.1
- $! On 5-NOV-1992 10:28:14.60 By user BERRYMAN
- $!
- $! The VMS_SHARE software that created this archive
- $! was written by Andy Harper, Kings College London UK
- $! -- September 1992
- $!
- $! Credit is due to these people for their original ideas:
- $! James Gray, Michael Bednarek
- $!
- $! TO UNPACK THIS SHARE FILE, CONCATENATE ALL PARTS IN ORDER
- $! AND EXECUTE AS A COMMAND PROCEDURE ( @name )
- $!
- $! THE FOLLOWING FILE(S) WILL BE CREATED AFTER UNPACKING:
- $! 1. AAAREADME.1ST;1
- $! 2. NOTICE.01;2
- $! 3. NOTICE.02;2
- $! 4. NOTICE.03;1
- $! 5. NOTICE.05;1
- $! 6. NOTICE.09;1
- $! 7. NOTICE.10;1
- $! 8. NOTICE.COM;2
- $! 9. NOTICE.HLP;3
- $!
- $set="set"
- $set symbol/scope=(nolocal,noglobal)
- $f=f$parse("SHARE_UNPACK_TEMP","SYS$SCRATCH:."+f$getjpi("","PID"))
- $e="write sys$error ""%UNPACK"", "
- $w="write sys$output ""%UNPACK"", "
- $ if .not. f$trnlnm("SHARE_UNPACK_LOG") then $ w = "!"
- $ ve=f$getsyi("version")
- $ if ve-f$extract(0,1,ve) .ges. "4.4" then $ goto start
- $ e "-E-OLDVER, Must run at least VMS 4.4"
- $ v=f$verify(v)
- $ exit 44
- $unpack: subroutine ! P1=filename, P2=checksum, P3=attributes
- $ if f$search(P1) .eqs. "" then $ goto file_absent
- $ e "-W-EXISTS, File ''P1' exists. Skipped."
- $ delete 'f'*
- $ exit
- $file_absent:
- $ if f$parse(P1) .nes. "" then $ goto dirok
- $ dn=f$parse(P1,,,"DIRECTORY")
- $ w "-I-CREDIR, Creating directory ''dn'"
- $ create/dir 'dn'
- $ if $status then $ goto dirok
- $ e "-E-CREDIRFAIL, Unable to create ''dn' File skipped."
- $ delete 'f'*
- $ exit
- $dirok:
- $ w "-I-UNPACK, Unpacking file ''P1'"
- $ n=P1
- $ if P3 .nes. "" then $ n=f
- $ if .not. f$verify() then $ define/user sys$output nl:
- $ EDIT/TPU/NOSEC/NODIS/COM=SYS$INPUT 'f'/OUT='n'
- PROCEDURE GetHex LOCAL x1,x2;x1:=INDEX(t,ERASE_CHARACTER(1))-1;x2:=INDEX(t,
- ERASE_CHARACTER(1))-1;RETURN 16*x1+x2;ENDPROCEDURE;
- PROCEDURE SkipPartsep LOOP EXITIF INDEX(ERASE_LINE,"-+-+-+-+-+-+-+-+")=1;
- ENDLOOP;ENDPROCEDURE;
- PROCEDURE ExpandChar CASE CURRENT_CHARACTER FROM ' ' TO 'z' ["`"]
- :ERASE_CHARACTER(1);COPY_TEXT(ASCII(GetHex));[" "]:ERASE_CHARACTER(1);[
- OUTRANGE,INRANGE]:MOVE_HORIZONTAL(1);ENDCASE;ENDPROCEDURE;
- PROCEDURE ProcessLine s:=ERASE_CHARACTER(1);LOOP EXITIF CURRENT_OFFSET>=LENGTH(
- CURRENT_LINE);ExpandChar;ENDLOOP;IF s="V" THEN APPEND_LINE;ENDIF;ENDPROCEDURE;
- PROCEDURE AdvanceLine MOVE_HORIZONTAL(-CURRENT_OFFSET);MOVE_VERTICAL(1);
- ENDPROCEDURE;PROCEDURE Decode POSITION(BEGINNING_OF(b));LOOP EXITIF MARK(NONE)=
- END_OF(b);IF INDEX(CURRENT_LINE,"+-+-+-+-+-+-+-+-")=1 THEN SkipPartSep;
- ELSE ProcessLine;AdvanceLine;ENDIF;ENDLOOP;ENDPROCEDURE;SET(FACILITY_NAME,
- "UNPACK");SET(SUCCESS,OFF);SET(INFORMATIONAL,OFF);t:="0123456789ABCDEF";f:=
- GET_INFO(COMMAND_LINE,"file_name");b:=CREATE_BUFFER(f,f);Decode;WRITE_FILE(b,
- GET_INFO(COMMAND_LINE,"output_file"));QUIT;
- $ if p3 .eqs. "" then $ goto dl
- $ open/write fdl &f
- $ write fdl "RECORD"
- $ write fdl P3
- $ close fdl
- $ w "-I-CONVRFM, Converting record format to ", P3
- $ convert/fdl=&f &f-1 &P1
- $dl: delete 'f'*
- $ if P2 .eqs. "" then $ goto ckskip
- $ checksum 'P1'
- $ if checksum$checksum .nes. P2 then $ -
- e "-E-CHKSMFAIL, Checksum of ''P1' failed."
- $ exit
- $ckskip: e "-W-CHKSUMSKIP, checksum validation unavailable for ''P1'"
- $ endsubroutine
- $start:
- $!
- $ create 'f'
- X`20`20`20This`20is`20the`20UWO`20CCS`20notice`20facility`20for`20HYDRA,`20a
- V`20VMS`20system.`20`20It`20is
- Xused`20to`20display`20important`20system`20notices`20to`20users`20when`20they
- V`20login.
- X
- XWARNING:`20`20Read`20the`20caveat`20in`20NOTICE.COM`20before`20you`20use`20thi
- Vs`20facility!
- X=======
- X
- X
- XFiles:
- X-----
- X
- XAAAREADME.1ST`09-`20this`20text.
- XNOTICE.01`09\
- XNOTICE.02`09`20\
- XNOTICE.05`09`20`20>--`20`20Saample`20notice`20files.
- XNOTICE.09`09`20/
- XNOTICE.10`09/
- XNOTICE.COM`09-`20The`20main`20com`20file`20with`20installation
- X`09`09`20`20directions`20provided`20at`20the`20end.
- XNOTICE.HLP`09-`20Help`20file`20sources.
- $ call unpack AAAREADME.1ST;1 1795177039 ""
- $!
- $ create 'f'
- XNew`20system`20notice`20facility
- X
- XThere`20is`20a`20new`20notice`20facility`20available.`20`20You`20are`20current
- Vly
- Xusing`20it`20to`20view`20this`20system`20notice.`20`20NOTICE`20has`20effect
- V`20only
- Xif`20you`20are`20logged`20on`20interactively.
- X
- XThe`20new`20notice`20facility`20is`20very`20similar`20to`20the`20earlier`20ver
- Vsion.
- XHowever,`20you`20may`20also`20type
- X
- X`20`20`20`20$`20NOTICE`20ALL`09`09to`20view`20all`20system`20notices
- X`20`20`20`20$`20NOTICE`20UNREAD`09`09to`20view`20unread`20system`20notices
- X`20`20`20`20$`20NOTICE`20nn`09`09`09to`20view`20system`20notice`20"nn"
- X`20`20`20`20$`20NOTICE`20DISABLE`09`09to`20disable`20"unread"`20notices
- X`09`09`09`09(for`20example`20at`20login`20time)
- X`20`20`20`20$`20NOTICE`20ENABLE`09`09to`20enable`20"unread"`20notices
- X`09`09`09`09(reverses`20the`20DISABLE`20function)
- X
- Xat`20any`20time`20after`20you`20are`20logged`20in.
- X
- XFor`20on-line`20help`20with`20NOTICE,`20type
- X
- X`20`20`20`20$`20HELP`20NOTICE`20`20`20<cr>
- X
- XPlease`20report`20problems`20to`20the`20program`20consultant.
- $ call unpack NOTICE.01;2 1080510803 ""
- $!
- $ create 'f'
- XCCS`20Charging`20and`20Accounting`20Policy`20(1991-92)
- X
- XThis`20document`20is`20available`20in`20the`20sys$help`20disk`20area.
- XTo`20view`20it,`20type
- X
- X$`20TYPE/PAGE`20SYS$HELP:CCS.POLICY`20`20`20<cr>
- X
- XThe`20file`20may`20be`20printed`20if`20you`20would`20like`20hard`20copy.
- $ call unpack NOTICE.02;2 1679064564 ""
- $!
- $ create 'f'
- XCCS`20prices`20are`20in`20sys$help
- XFor`20more`20information`20about`20CCS`20prices`20enter:
- X
- X$`20TYPE/PAGE`20SYS$HELP:CCS.PRICES
- X
- $ call unpack NOTICE.03;1 1365971511 ""
- $!
- $ create 'f'
- XDepartmental`20computing`20expenditures
- X
- XThe`20latest`20departmental`20computing`20expenditures`20are
- Xavailable`20in`20the`20notice`20area.`20`20To`20view`20it,`20type
- X
- X$`20TYPE/PAGE`20NOTICE:REPORT.DEP`20`20`20`20<cr>
- X
- XThe`20file`20may`20be`20printed`20if`20you`20would`20like`20hard`20copy.
- $ call unpack NOTICE.05;1 222452932 ""
- $!
- $ create 'f'
- XCCS`20Services`20Price`20List`20(effective`20May`201,`201991)
- X
- XThe`20CCS`20Services`20Price`20List`20document`20is`20available`20in`20the
- Xsys$help`20disk`20area.`20`20To`20view`20it,`20type
- X
- X$`20TYPE/PAGE`20SYS$HELP:CCS.PRICES`20`20`20<cr>
- X
- XThe`20file`20may`20be`20printed`20if`20you`20would`20like`20hard`20copy.
- $ call unpack NOTICE.09;1 1081016876 ""
- $!
- $ create 'f'
- XMicro`20Lab`20Availability`20Schedule
- X
- XThe`20current`20Micro`20Lab`20Availability`20Schedule`20is`20available
- Xin`20the`20notice`20area.`20`20To`20view`20it,`20type
- X
- X$`20TYPE/PAGE`20NOTICE:PC.LAB`20`20`20`20<cr>
- X
- XThe`20file`20may`20be`20printed`20if`20you`20would`20like`20hard`20copy.
- $ call unpack NOTICE.10;1 1181305932 ""
- $!
- $ create 'f'
- X$`20!`09NOTICE.COM.`09NOTICE.COM`20is`20a`20command`20procedure`20for`20displa
- Vying
- X$`20!`09==========`09system`20notices.`20`20Written`20by`20Brent`20Sterner,
- V`20CCS,`20UWO.
- X$`20!`09`09`09Copyright`20(c)`201991.`20`20Permission`20is`20granted`20to`20co
- Vpy,
- X$`20!`09`09`09modify,`20and`20use`20this`20procedure`20and`20it's`20techniques
- V
- X$`20!`09`09`09provided`20the`20source`20is`20acknowledged.
- X$`20!`09`09`09
- X$`20!`09WARNING:`20`20This`20command`20procedure`20plays`20a`20game`20with`20t
- Vhe`20expiry`20date
- X$`20!`09-------`09`20`20of`20each`20user's`20home`20directory.`20`20For`20an
- V`20explanation,`20refer
- X$`20!`09`09`20`20to`20the`20functionality`20details`20which`20can`20be`20found
- V`20at`20the
- X$`20!`09`09`20`20end`20of`20this`20file.`20`20There`20is`20also`20an`20accompa
- Vnying`20help
- X$`20!`09`09`20`20file`20suitable`20for`20including`20in`20a`20help`20library,
- V`20such`20as
- X$`20!`09`09`20`20sys$help:helplib.hlb.
- X$`20!
- X$`20!
- X$`20!`09NOTICE:`09This`20procedure`20does`20*nothing*`20if`20we`20are`20not
- V`20interactive!
- X$`20!`09------
- X$`09`09IF`20F$MODE()`20.NES.`20"INTERACTIVE"`20THEN`20EXIT
- X$`20!
- X$`20!`09Assumes`20the`20logical`20"NOTICE"`20has`20been`20defined`20which`20in
- Vdicates`20where
- X$`20!`09the`20notice`20messages`20reside.`20`20On`20the`20author's`20system,
- V`20the`20following
- X$`20!`09line`20appears`20in`20systartup_v5.com:
- X$`20!
- X$`20!`09`09DEFINE/SYSTEM`09notice`09ccsdisk:`5B1_2.notice`5D
- X$`20!
- X$`20!`09Translate`20the`20logical.
- X$`20!
- X$`09notice_log`20=`20f$trnlnm("notice","LNM$SYSTEM_TABLE")
- X$`20!
- X$`20!`09This`20symbol`20is`20a`20flag`20date.`20`20When`20used`20as`20the`20ex
- Vpiry`20date`20for`20a
- X$`20!`09user's`20sys$login`20home`20directory,`20it`20means`20"do`20not`20disp
- Vlay`20unread
- X$`20!`09notices"`20to`20the`20NOTICE`20UNREAD`20command.
- X$`20!
- X$`09suppress_notices`20=`20"1-jan-9999"
- X$`20!
- X$`20!`09Establish`20the`20basics.`20`20When`20did`20this`20user`20last`20read
- V`20system`20notices?
- X$`20!
- X$`09t1`20=`20f$trnlnm("sys$login")`09`09!`20User`20login`20directory.
- X$`09t2`20=`20f$parse("sys$login",,,"DIRECTORY")`20-`20"`5B"`20-`20"`5D"`20+
- V`20".DIR"
- X$`09t3`20=`20t1`20-`20"`5D"`20+`20".-`5D''t2'"`09`09!`20"sys$login"`20file`20s
- Vpec.
- X$`20!
- X$`20!`20`20The`20expiry`20date`20of`20the`20home`20directory`20is`20set`20to
- V`20100`20years`20(exactly)
- X$`20!`20`20after`20the`20date/time`20the`20user`20reads`20system`20notices.
- V`20`20So,`20...
- X$`09t4`20=`20f$cvtime(f$file_attributes(t3,"EDT"))`20`20!`20100`20years`20high
- V.
- X$`09t5`20=`20f$extract(0,4,t4)`09`09`09`20`20`20`20!`20The`20year...
- X$`09t6`20=`20"''t4'"`20-`20"''t5'"`09`09`09`20`20`20`20!`20`20`20`20`20`20`20
- V`20`20...`20the`20rest.
- X$`09t7`20=`20f$string(t5-100)`20+`20"''t6'"`09`09`20`20`20`20!`20Reconstructiv
- Ve`20surgery.
- X$`20!
- X$`20!`09Figure`20out`20"now"`20in`20a`20similar`20way,`20but`20add`20100`20yea
- Vrs`20to`20that.
- X$`09n1`20=`20f$time()`09`09`09`09`20`20`20`20!`20Establish`20this`20moment.
- X$`09n2`20=`20f$cvtime(n1,"ABSOLUTE","DATE")`09`20`20`20`20!`20Date`20part.
- X$`09n3`20=`20f$edit(n1-n2,"TRIM")`09`09`20`20`20`20!`20Time`20part.
- X$`09n4`20=`20f$cvtime(n1,"ABSOLUTE","YEAR")`09`20`20`20`20!`20This`20year.
- X$`09n5`20=`20n2`20-`20n4`20+`20f$string(n4+100)`20`20-
- X`09`09+`20":"`20+`20n3`09`09`09`20`20`20`20!`20"now"`20+`20100`20years.
- X$`20!
- X$`20!`09Decide`20what`20to`20do`20now.`20`20This`20depends`20on`20P1.`09!\
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20""`20`20`20`20`20`20`20`20then`20goto`20pr
- Vompt`09!`20\`20`20`20`20
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20"LIST"`20`20`20`20then`20goto`20prompt`09!
- V`20`20\`20`20`20Split`20up
- X$`20if`20f$type(p1)`20.eqs.`20"INTEGER"`20then`20goto`20integer`09!`20`20`20\
- V`20`20here,`20and
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20"ALL"`20`20`20`20`20then`20goto`20all`09
- V`09!`20`20`20/`20`20meet`20up`20at
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20"UNREAD"`09then`20goto`20unread`09!`20`20/
- V`20`20`20the`20"exit".
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20"DISABLE"`20then`20goto`20disable`09!`20/
- X$`20if`20"''p1'"`20`20`20`20.eqs.`20"ENABLE"`20`20then`20goto`20enable`09!/
- X
- X$`20!
- X$`20!
- X$`20!`09If`20we`20cannot`20decide`20what`20to`20do,`20complain`20and`20exit.
- X$`20DIAGNOSTIC:
- X$`20type`20sys$input
- X%NOTICE-W-IVKEYW,`20unrecognized`20keyword`20-`20check`20validity`20and`20spel
- Vling
- X$`20write`20sys$output`20"`20\''p1'\"
- X$`20exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20ENABLE:`09!`20Here`20to`20"enable"`20display`20of`20unread`20system`20noti
- Vces.
- X$`09set`20file/expiration_date=today`20't3
- X$`09write`20sys$output`09`09-
- X`09`09"%NOTICE-I-ENABLED,`20Unread`20notice`20display`20is`20now`20enabled"
- X$`09exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20DISABLE:`09!`20Here`20to`20"disable"`20display`20of`20unread`20system`20no
- Vtices.
- X$`09set`20file/expiration_date='suppress_notices`20't3
- X$`09write`20sys$output`09`09-
- X`09`09"%NOTICE-I-DISABLED,`20Unread`20notice`20display`20is`20now`20disabled"
- X$`09exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20UNREAD:`09!`20Here`20to`20display`20unread`20notices.
- X$`09temp`20=`20f$cvtime(suppress_notices)
- X$`09if`20"''t4'"`20.eqs.`20"''temp'"`20
- X$`09`20`20`20then`20write`20sys$output`09-
- X`09`20`20`20`20`20"%NOTICE-I-DISABLED,`20Unread`20notice`20display`20is`20curr
- Vently`20disabled"
- X$`09`20`20`20exit
- X$`09endif
- X$`20!
- X$`20`20`20`20`20`20`20notice_count`20=`200`09`09`09!`20Notice`20counter.
- X$`20`20`20`20`20`20`20notice_file`20=`20""`09`09`09!`20File`20name`20of`20noti
- Vce...
- X$`20UNREAD_LOOP:
- X$`09gosub`20notice_file`09`09`09!`20notice`20file`20candidate.
- X$`09if`20"''notice_file'"`20.nes.`20""
- X$`09`20`20`20`20then`09`09`09`09!`20When`20was`20this`20file`20revised?
- X$`09`09file_time`20=`20f$cvtime(f$file_attributes(notice_file,"RDT"))
- X$`09`09if`20"''file_time'"`20.gts.`20"''t7'"`09!`20If`20an`20unseen`20file`20.
- V..
- X$`09`09`20`20`20`20then`20type`20'notice_file`09!`20`20`20`20`20`20`20`20`20..
- V.`20type`20it`20out.
- X$`09`09`20`20`20`20notice_count`20=`20notice_count`20+`201`09!`20...`20and`20c
- Vount`20it.
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20write`20sys$output`20""`09`09!`20Be
- V`20tidy.
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20inquire`20dummy`20`09`09-
- X`09`09"`09`09`09<Press`20RETURN`20to`20continue>`20"
- X$`09`09endif`09`09`09`09!`20Otherwise,`20ignore`20it.
- X$`09`09goto`20unread_loop
- X$`09else`09`09`09`09`09!`20Here`20to`20stamp`20sys$login`20...
- X$`09`09set`20file/expiration_date="''n5'"`20't3
- X$`09endif
- X$`20exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20ALL:`09`09!`20Here`20to`20display`20"all"`20current`20notices.
- X$`09notice_count`20=`200
- X$`09notice_file`20:==`20""
- X$`20ALL_LOOP:
- X$`09gosub`20notice_file`09`09`09!`20notice`20file`20candidate.
- X$`09if`20"''notice_file'"`20.nes.`20""
- X$`09`20`20`20`20then`20`20`20`20type`20'notice_file`09`09!`20Got`20one.`20`20T
- Vype`20it`20out.
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20write`20sys$output`20""`09`09!`20Be
- V`20tidy.
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20inquire`20dummy`20`09`09-
- X`09`09"`09`09`09<Press`20RETURN`20to`20continue>`20"
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20notice_count`20=`20notice_count`20+
- V`201`09!`20Count`20me.
- X$`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20goto`20all_loop`20
- V`20`20`20`20`20`20`20`20`09!`20Loop`20through`20each`20file
- X$`09`20`20`20`20else`09`09`09`09!`20No`20more`20files,`20so...
- X$`09`09temp`20=`20f$cvtime(suppress_notices)
- X$`09`09if`20"''t4'"`20.nes.`20"''temp'"`20
- X$`09`09`20`20`20`20then`20set`20file/expiration_date="''n5'"`20't3`20`20!`20st
- Vamp`20sys$login
- X$`09`09`20`20`20`20else`20write`20sys$output`09-
- X`09`09`20`20"%NOTICE-I-DISABLED,`20Unread`20notice`20display`20is`20still`20di
- Vsabled"
- X$`09`09endif
- X$`09endif
- X$`20`20`20`20`20`20`20if`20notice_count`20.eq.`200`20then`09`09-
- X`09`09write`20sys$output`20"%NOTICE-W-NONOTICE,`20no`20notices`20found"
- X$`09exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20INTEGER:`09!`20Here`20to`20display`20notice.<n>.
- X
- X$`20!`20Add`20a`20leading`20zero`20to`20p1`20if`20necessary`20...
- X$`09temp`20=`20"0000"`20+`20"''p1'"
- X$`09number`20=`20f$extract(f$length(temp)-2,2,temp)
- X$`09file`20=`20f$search("''notice_log'notice.''number';")
- X$`09if`20"''file'"`20.eqs.`20""
- X$`09`20`20`20`20then`20`20`20`20write`20sys$output`20"%NOTICE-W-NONOTICE,`20no
- V`20notice`20found"
- X$`09`20`20`20`20else`20`20`20`20write`20sys$output`20"`20`20`20`20Notice`20''p
- V1':"
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20type`20'file
- X$`09endif
- X$`09exit
- X$`20!
- X$`20!`09---------------------------------------------------------------
- X$`20!
- X$`20PROMPT:`09!`20Here`20to`20decide`20which`20message`20to`20display.
- X$`09notice_count`20=`200
- X$`09notice_file`20=`20""
- X$`20PROMPT_loop:
- X$`09gosub`20notice_file
- X$`09if`20"''notice_file'"`20.nes.`20""
- X$`09`20`20`20`20then`20`20`20`20open/read/share=read`20note`20'notice_file
- X$`09`09`20`20`20`20read`20note`20first_record
- X$`09`09`20`20`20`20close`20note
- X$`20!`20Tidy`20up`20leading`20zeros...
- X$`09`09`20`20`20`20num`20=`20ftype
- X$`09`09`20`20`20`20if`20num`20.lt`2010`20then`20num`20=`20num`20-`20"0"
- X$`20!`20Pad`20with`20spaces...
- X$`09`09`20`20`20`20temp`20=`20"`20`20`20`20"`20+`20num
- X$`09`09`20`20`20`20num`20=`20f$extract(f$length(temp)-4,4,temp)
- X$`09`09`20`20`20`20display`20=`20"''num'"`20+`20"`09''first_record'"
- X$`09`09`20`20`20`20if`20notice_count`20.eq.`200`20then`20write`20sys$output
- V`09-
- X`09`09`09`09`09`09`09"Notice`09Subject"
- X$`09`09`20`20`20`20write`20sys$output`20"''display'"
- X$`09`20`20`20`20`20`20`20`20`20`20`20`20notice_count`20=`20notice_count`20+
- V`201
- X$`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20`20goto`20prompt_loop
- V`20`20`20`20`20`20`20`20`20!`20Loop`20through`20each`20file.
- X$`09endif
- X$`20`20`20`20`20`20`20if`20notice_count`20.eq.`200
- X$`09`20`20`20`20then`20`20`20`20write`20sys$output`20"%NOTICE-W-NONOTICE,`20no
- V`20notices`20found"
- X$`09`20`20`20`20else`20`20`20`20inquire`20number`20"Notice`20number`20you`20wo
- Vuld`20like`20to`20see"
- X$`09`09`20`20`20`20if`20"''number'"`20.eqs.`20""`20then`20exit
- X$`20!`20Add`20a`20leading`20zero`20if`20necessary`20...
- X$`09`09`20`20`20`20temp`20=`20"0000"`20+`20"''number'"
- X$`09`09`20`20`20`20number`20=`20f$extract(f$length(temp)-2,2,temp)
- X$`09`09`20`20`20`20file`20=`20f$search("''notice_log'notice.''number';")
- X$`09`09`20`20`20`20if`20"''file'"`20.eqs.`20""`20then`20goto`20prompt
- X$`09`09`20`20`20`20type`20'file
- X$`09endif
- X$`09exit
- X$`20!
- X$`20!`09-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20
- V`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20
- V`20-`20`20-`20`20-`20`20-`20`20-
- X$`20!`09-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20
- V`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20`20-`20
- V`20-`20`20-`20`20-`20`20-`20`20-
- X$`20!
- X$`20!`09GOSUB`20to`20this`20routine`20to`20locate`20the`20next`20notice`20file
- V...
- X$`20notice_file:`09`09`09!`20Locate`20the`20next`20notice`20file.
- X$`20loop:
- X$`09notice_file`20=`20f$search("''notice_log'notice.*;")`20!`20Find`20a`20noti
- Vce`20candidate.
- X$`09if`20"''notice_file'"`20.eqs.`20""`20then`20return`20`20`20`20`20!`20""
- V`20means`20no`20more.
- X$`09ftype`20=`20f$parse(notice_file,,,"TYPE")`20-`20"."`20`20!`20File`20extens
- Vion`20(no`20dot).
- X$`09if`20f$type(ftype)`20.nes.`20"INTEGER"`20then`20goto`20loop
- X$`20`09`09`09`09`09`09!`20Ignore`20inappropriate`20files.
- X$`20return`09`09`09`09`09!`20Return
- X$`20exit`09`09`09`09!`20Just`20in`20case`20my`20DCL`20ain't`20so`20good...
- X$`20!
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================`20`20`20`20D`20O`20C`20U`20M`20E`20N`20T`20A`20T`20I
- V`20O`20N`20`20`20`20===============
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================`20`20`20`20`20Procedure`20`20`20Description`20`20`20
- V`20`20===============
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!`09================================================================
- X$`20!
- X$`20!
- X$`20!`09NOTICE.COM.`09NOTICE.COM`20is`20a`20command`20procedure`20for`20displa
- Vying
- X$`20!`09==========`09system`20notices.`20`20Written`20by`20Brent`20Sterner,
- V`20CCS,`20UWO.
- X$`20!`09`09`09Copyright`20(c)`201991.`20`20Permission`20is`20granted`20to`20co
- Vpy,
- X$`20!`09`09`09modify,`20and`20use`20this`20procedure`20and`20it's`20techniques
- V
- X$`20!`09`09`09provided`20the`20source`20is`20acknowledged.
- X$`20!
- X$`20!`09Suggestions...`09Please`20send`20suggestions`20for`20improving`20this
- V`20command
- X$`20!`09`09`09procedure`20to`20the`20author:
- X$`20!
- X$`20!`09Brent`20Sterner`20`20`20Manager,`20Academic`20Technical`20Support
- X$`20!`09`20`20`20`20Fast:`09<BRENT@uwo.ca>`09`09<129.100.2.13>
- X$`20!`09`20`20`20`20Telephone:`09(519)661-2151`20x6036
- X$`20!`09`20`20`20`20Slow:`09Computing`20`26`20Communications`20Services,
- X$`20!`09`09`09Natural`20Sciences`20Building,
- X$`20!`09`09`09The`20University`20of`20Western`20Ontario,
- X$`20!`09`09`09London,`20Ontario,`20Canada`20`20`20`20N6A`205B7
- X$`20!
- X$`20!`09Technical`20details:
- X$`20!
- X$`20!`09`20`20`20`20WARNING:`09NOTICE.COM`20abuses`20the`20expiry`20date`20on
- V`20each`20user's
- X$`20!`09`20`20`20`20-------`09home`20directory`20in`20the`20following`20way.
- V`20`20Whenever
- X$`20!`09`09`09system`20notices`20are`20"caught`20up"`20(with`20either`20the
- X$`20!`09`09`09"ALL"`20or`20"UNREAD"`20parameters,`20the`20expiry`20date
- X$`20!`09`09`09for`20the`20user's`20home`20directory`20is`20set`20to`20"now"
- X$`20!`09`09`09plus`20100`20years.`20`20The`20"UNREAD"`20option`20extracts
- X$`20!`09`09`09this`20expiry`20date,`20subtracts`20100`20years,`20and`20checks
- X$`20!`09`09`09the`20"revised"`20date/time`20of`20each`20notice`20file.
- X$`20!`09`09`09This`20has`20had`20no`20adverse`20side`20effects`20at`20this`20s
- Vite.
- X$`20!`09`09`09However,`20no`20guarantee`20can`20be`20made`20that`20your`20site
- V
- X$`20!`09`09`09will`20not`20be`20affected`20in`20some`20way.
- X$`20!
- X$`20!`09`09`09Additionally,`20a`20user`20can`20disable`20(and`20re-enable)
- X$`20!`09`09`09"unread"`20notices.`20`20The`20special`20date`20indicated`20by
- X$`20!`09`09`09the`20symbol`20"uppress_notices"`20flags`20"unread"`20notice
- X$`20!`09`09`09suppression.
- X$`20!
- X$`20!`09`09NOTICE.COM`20depends`20on`20a`20system`20logical,`20NOTICE,`20and
- V`20the
- X$`20!`09`09symbol`20NOTICE`20which`20invokes`20NOTICE.COM.`20`20Specifically,
- X$`20!`09`09at`20the`20author's`20site,`20the`20following`20definition`20appear
- Vs
- X$`20!`09`09in`20systartup_v5.com:
- X$`20!
- X$`20!`09`09`20`20`20`20$`20DEFINE/SYSTEM`20`20notice`20`20ccsdisk:`5B1_2.notic
- Ve`5D
- X$`20!
- X$`20!`09`09and`20sylogin.com`20contains`20the`20line:
- X$`20!
- X$`20!`09`09`20`20`20`20$`20NOT*ICE`20:==`20"@NOTICE:NOTICE.COM"
- X$`20!
- X$`20!`09`09Operations`20staff`20have`20complete`20control`20of`20this`20area.
- X$`20!`09`09Their`20duties`20include`20management`20of`20the`20system`20notice
- X$`20!`09`09data`20files`20which`20are`20kept`20there.`20`20By`20convention,
- V`20any
- X$`20!`09`09file`20in`20this`20area`20named`20NOTICE.nn`20(where`20the`20lexica
- Vl
- X$`20!`09`09f$type(nn)`20is`20"INTEGER")`20is`20a`20system`20notice`20file.`20
- V`20As
- X$`20!`09`09a`20practical`20matter,`20always`20use`20a`20two`20digit`20extensio
- Vn
- X$`20!`09`09for`20the`20file,`20to`20prevent`20notice.10`20preceding`20notice.9
- V.
- X$`20!`09`09
- X$`20!`09Call`20via`20(assuming`20NOT*ICE`20:==`20@NOTICE.COM):
- X$`20!`09`20`20`20`20$`20NOTICE`20UNREAD`09-`20Display`20unread`20notices`20via
- V`20the`20TYPE
- X$`20!`09`09`09`09`20`20command.`20`20The`20user`20must`20type`20a`20<cr>
- X$`20!`09`09`09`09`20`20after`20each`20message`20before`20he`20sees`20the
- X$`20!`09`09`09`09`20`20next`20message.`20`20After`20all`20unread`20notices
- X$`20!`09`09`09`09`20`20have`20been`20displayed,`20the`20expiry`20field
- X$`20!`09`09`09`09`20`20of`20sys$login`20is`20corrupted`20with`20the
- X$`20!`09`09`09`09`20`20current`20date/time`20"plus`20100`20years".
- X$`20!`09`09`09`09`20`20This`20is`20the`20login`20behaviour.
- X$`20!`09`20`20`20`20$`20NOTICE`20ALL`09-`20Display`20all`20messages`20(read
- V`20or`20not)`20via
- X$`20!`09`09`09`09`20`20the`20TYPE`20command.`20`20The`20user`20must`20type
- X$`20!`09`09`09`09`20`20a`20<cr>`20after`20each`20message`20before`20he`20sees
- X$`20!`09`09`09`09`20`20the`20next`20message.`20`20The`20expiry`20field`20of
- X$`20!`09`09`09`09`20`20sys$login`20is`20then`20updated`20as`20in`20"UNREAD".
- X$`20!`09`20`20`20`20$`20NOTICE`20<n>`09-`20Display`20system`20notice`20"n"`20o
- Vnly.`20`20Does`20not
- X$`20!`09`09`09`09`20`20update`20sys$login`20(user`20may`20see`20this`20system
- X$`20!`09`09`09`09`20`20notice`20again`20at`20login).
- X$`20!`09`20`20`20`20$`20NOTICE`20LIST`09-`20Displays`20the`20first`20line`20fr
- Vom`20all`20available
- X$`20!`09`09`09`09`20`20system`20notices,`20prompts`20user`20for`20which`20to
- X$`20!`09`09`09`09`20`20display,`20and`20does`20so.`20`20A`20conversational
- X$`20!`09`09`09`09`20`20version`20of`20NOTICE`20<n>.`20`20Does`20not`20update
- X$`20!`09`09`09`09`20`20sys$login`20(user`20may`20see`20this`20message`20again)
- V.
- X$`20!`09`09`09`09`20`20This`20is`20the`20default`20behaviour`20if`20NOTICE
- X$`20!`09`09`09`09`20`20is`20run`20with`20no`20parameter`20specified.
- X$`20!
- X$`20!`09`20`20`20`20$`20NOTICE`20DISABLE`09-`20Disables`20the`20display`20of
- V`20unread`20notices.
- X$`20!
- X$`20!`09`20`20`20`20$`20NOTICE`20ENABLE`09-`20Enables`20normal`20behaviour`20o
- Vf`20NOTICE`20UNREAD.
- X$`20!
- X$`20!
- X$`20!
- X$`20!`09INSTALLATION:
- X$`20!`09------------
- X$`20!`09`09Installation`20is`20straightforward:
- X$`20!`09`090)`20BEWARE:`20`20Before`20you`20begin,`20read`20the`20caveat`20abo
- Vut`20how
- X$`20!`09`09`20`20`20------`20`20`20this`20procedure`20abuses`20the`20expiry
- V`20date`20on`20each
- X$`20!`09`09`20`20`20`20`20`20`20`20`20`20`20`20user's`20sys$login`20file.`20
- V`20Our`20site`20uses`20volume
- X$`20!`09`09`20`20`20`20`20`20`20`20`20`20`20`20retention,`20and`20this`20has
- V`20not`20caused`20us`20any
- X$`20!`09`09`20`20`20`20`20`20`20`20`20`20`20`20observed`20ill`20behaviour.`20
- V`20But`20I`20offer`20no
- X$`20!`09`09`20`20`20`20`20`20`20`20`20`20`20`20guarantee`20it`20won't`20hurt
- V`20your`20site`20in`20some`20way.
- X$`20!`09`091)`20Create`20a`20suitable`20directory`20in`20which`20to`20keep`20s
- Vystem
- X$`20!`09`09`20`20`20notices.`20`20At`20our`20site,`20they`20are`20kept`20in
- V`20a`20directory
- X$`20!`09`09`20`20`20called`20CCSDISK:`5B1_2.NOTICE`5D.
- X$`20!`09`092)`20Create`20a`20system`20logical`20NOTICE`20pointing`20to`20this
- X$`20!`09`09`20`20`20directory.`20`20At`20our`20site,`20the`20systartup_v5.com
- V`20file
- X$`20!`09`09`20`20`20does`20this`20at`20boot`20time`20with`20the`20command:
- X$`20!`09`09`09DEFINE/SYSTEM`09notice`09ccsdisk:`5B1_2.notice`5D
- X$`20!`09`093)`20Copy`20this`20command`20procedure`20into`20a`20permanent`20hom
- Ve.
- X$`20!`09`09`20`20`20At`20CCS,`20we`20keep`20the`20command`20procedure`20in`20t
- Vhe`20"notice"
- X$`20!`09`09`20`20`20directory,`20CCSDISK:`5B1_2.NOTICE`5D.`20`20Make`20sure
- V`20the`20file
- X$`20!`09`09`20`20`20protection`20on`20this`20file`20allows`20world`20read`20(W
- V:R)`20access.
- X$`20!`09`094)`20Define`20the`20NOTICE`20symbol`20for`20every`20user`20at`20log
- Vin`20time.
- X$`20!`09`09`20`20`20At`20CCS,`20sylogin.com`20contains`20the`20line:
- X$`20!`09`09`09$`20NOTICE`20:==`20"@NOTICE:NOTICE.COM"
- X$`20!`09`095)`20Create`20some`20notice`20files`20in`20the`20notice`20area.`20
- V`20Notice
- X$`20!`09`09`20`20`20files`20have`20the`20name`20convention`20NOTICE.nn,`20wher
- Ve`20"nn"
- X$`20!`09`09`20`20`20is`20an`20integer.`20`20It`20is`20best`20to`20make`20"nn"
- V`20a`20two`20digit
- X$`20!`09`09`20`20`20integer`20(ie`20use`20"04",`20not`20"4")`20to`20cause`20VM
- VS`20to`20locate
- X$`20!`09`09`20`20`20notice`20files`20in`20numerical`20order.`20`20(File`20orde
- Vr`20in`20VMS
- X$`20!`09`09`20`20`20is`20text-based,`20so`20"file.10"`20will`20precede`20"file
- V.9"`20in
- X$`20!`09`09`20`20`20a`20directory`20or`20lexical`20file`20search.)
- X$`20!`09`096)`20Note`20that`20the`20"LIST"`20parameter`20causes`20the`20first
- V`20line
- X$`20!`09`09`20`20`20of`20each`20notice`20file`20to`20be`20displayed.`20`20This
- V`20feature`20is
- X$`20!`09`09`20`20`20intended`20to`20provide`20a`20"header"`20or`20title`20for
- V`20each`20notice.
- X$`20!`09`09`20`20`20Experiment`20with`20this`20first`20line`20until`20you`20ac
- Vhieve`20the
- X$`20!`09`09`20`20`20results`20you`20desire.
- X$`20!`09`097)`20NOTICE.HLP`20exists,`20and`20is`20suitable`20for`20including
- V`20in
- X$`20!`09`09`20`20`20your`20local`20help`20library.`20`20See`20the`20"VMS`20Lib
- Vrarian`20Utility`20
- X$`20!`09`09`20`20`20Manual"`20if`20you`20would`20like`20to`20install`20NOTICE.
- VHLP.
- $ call unpack NOTICE.COM;2 175904062 ""
- $!
- $ create 'f'
- X1`20`20NOTICE
- X`20`20`20Displays`20system`20notices`20if`20you`20are`20logged`20on`20interact
- Vively.
- X`20`20`20(In`20every`20other`20mode,`20NOTICE`20does`20nothing).`20`20The`20NO
- VTICE
- X`20`20`20command`20can:
- X
- X`20`20`20`20`20o`20`20Display`20every`20existing`20system`20notice.
- X
- X`20`20`20`20`20o`20`20Display`20a`20list`20of`20existing`20system`20notices.
- X
- X`20`20`20`20`20o`20`20Display`20a`20specific`20system`20notice.
- X
- X`20`20`20`20`20o`20`20Display`20system`20notices`20which`20you`20have`20not
- V`20yet`20seen.
- X
- X`20`20`20`20`20o`20`20Disable`20or`20disable`20viewing`20of`20"unseen"`20syste
- Vm`20notices.
- X
- X`20`20`20Format
- X
- X`20`20`20`20`20`20`20`20NOTICE`20`20`5Bparameter`5D
- X
- X2`20`20PARAMETERS
- X
- X<n>
- X`20`20`20Displays`20system`20notice`20number`20<n>`20if`20it`20exists.
- X
- XALL
- X`20`20`20Displays`20every`20existing`20system`20notice.
- X
- XUNREAD
- X`20`20`20Displays`20system`20notices`20which`20you`20have`20not`20yet`20seen.
- V`20`20This
- X`20`20`20form`20of`20the`20NOTICE`20command`20is`20invoked`20automatically`20e
- Vvery
- X`20`20`20time`20you`20login`20an`20interactive`20session`20on`20CCS's`20VAX
- V`20system,
- X`20`20`20in`20an`20attempt`20to`20ensure`20you`20are`20aware`20of`20the`20stat
- Ve`20of`20the
- X`20`20`20system.`20`20You`20may`20enable`20or`20disable`20this`20behaviour`20b
- Vy`20using
- X`20`20`20the`20ENABLE`20or`20DISABLE`20parameters`20(see`20below).
- X
- XLIST
- X`20`20`20Displays`20a`20list`20of`20existing`20system`20notices`20and`20lets
- V`20you
- X`20`20`20select`20which`20notice`20your`20would`20like`20to`20see.`20`20This
- V`20is`20the
- X`20`20`20default`20behaviour`20of`20the`20NOTICE`20command`20for`20an`20intera
- Vctive
- X`20`20`20session`20if`20no`20parameter`20is`20specified.
- X
- XDISABLE
- X`20`20`20Flags`20your`20account`20so`20that`20unread`20system`20notices`20are
- V`20not`20displayed
- X`20`20`20(see`20"UNREAD"`20parameter).`20`20Since`20"NOTICE`20UNREAD"`20is`20i
- Vnvoked`20when
- X`20`20`20you`20login,`20use`20of`20this`20parameter`20effectively`20cancels
- V`20interactive
- X`20`20`20system`20notices`20at`20login`20time.
- X
- XENABLE
- X`20`20`20Flags`20your`20account`20so`20that`20unread`20system`20notices`20are
- V`20displayed
- X`20`20`20(see`20"UNREAD"`20parameter).`20`20Since`20it`20is`20not`20clear`20wh
- Vich`20system
- X`20`20`20notices`20you`20have`20not`20seen,`20the`20effect`20on`20the`20next
- V`20"NOTICE`20UNREAD"
- X`20`20`20command`20is`20to`20display`20every`20existing`20system`20notice.
- X
- X
- X`20`20`20Note`20that`20in`20all`20system`20notice`20displays,`20the`20notice
- V`20numbers
- X`20`20`20need`20not`20be`20consecutive.`20`20The`20notice`20number`20is`20simp
- Vly`20a
- X`20`20`20convenient`20reference`20for`20you`20and`20for`20operations`20staff
- V`20who
- X`20`20`20maintain`20system`20notices.
- X
- X2`20`20EXAMPLE
- X
- X`20`20`201.`20`20$`20NOTICE
- X`20`20`20`20`20`20`20Notice`20`20Subject
- X`20`20`20`20`20`20`20`20`20`201`20`20`20`20Micro`20Lab`20Schedule
- X`20`20`20`20`20`20`20`20`20`202`20`20`20`20CCS`20POLICY
- X`20`20`20`20`20`20`20`20`20`204`20`20`20`20CCS`20PRICES
- X`20`20`20`20`20`20`20`20`2015`20`20`20`20DEPARTMENTAL`20EXPENDITURES
- X`20`20`20`20`20`20`20Notice`20number`20you`20would`20like`20to`20see:`202
- X`20`20`20`20`20`20`20CCS`20POLICY
- X
- X`20`20`20`20`20`20`20For`20more`20information`20about`20CCS`20policy`20enter:
- X
- X`20`20`20`20`20`20`20$`20TYPE/PAGE`20SYS$HELP:CCS.POLICY
- $ call unpack NOTICE.HLP;3 1783080640 ""
- $ v=f$verify(v)
- $ exit
-