! Post changes to sets in elog subroutine elogPostSet(setName, oldnum, newnum) use str_find_mod implicit none character:: setname*(*) integer*4:: oldnum integer*4:: newnum character,save:: line*95 integer*4,save:: lun, slen character,save:: filename*80, ffn*120, fd*120 logical,save:: filexist, addcom real*4 :: secnds logical :: valid, err integer*4 :: lenstr ! ----------------end_declare--------------------------- ! prepare standard notice of set update line=' ' slen = lenstr(setName) write(line(1:slen), '(a)') setName(1:slen) write(line(17:),'(4hold:,i6,8h -> new:,i6)') oldnum, newnum ! get a unique output filename filename = ' ' write(filename,'(''$CESR_CONFIG/elog/scr/route_''i8.8,''.html'')') int(100.*secnds(0.0)) call fullfilename(filename, ffn, valid) ! add user comments if desired addcom = .false. call logic_get('Y','N','Add comment to elog entry? (Y/N)',addcom) ! if(addcom) call lib$spawn('@u:[cesr.com]edit_for_elog '//filename) if(addcom) call system('emacs '//ffn) ! post the changes to elog lun = lunget() inquire(file=ffn, exist=filexist) if(filexist) then ! open(lun, carriagecontrol='LIST', file=filename, status='old', access='append') call openap(lun, ffn, err, 0) else ! open(lun, carriagecontrol='LIST',file=filename,status='new') call openwr(lun, ffn, err, 0) endif write(lun,'(a)') ' New saveset in route: '//line(1:lenstr(line))//'' write(lun,'('''')') close(lun) ! this is what needs to be ported to alphsa for this routine to work ! call lib$spawn('@u:[cesr.com]elog_route '//filename,, 'u:[cesr.elog.scr]route.out',1) call fullfilename('$CESR_CONFIG/elog/', fd, valid) call system('mv '//ffn//' '//fd) return end