|
global ptp_file_name$ C6 v- z/ h- x6 J9 u
set tmp_file_name "${ptp_file_name}_"
0 M4 p7 d: t+ Gif {[file exists $tmp_file_name]} { MOM_remove_file $tmp_file_name }
+ ~8 g& p0 {3 a' D6 b' }MOM_close_output_file $ptp_file_name
8 G8 [8 A# n4 A8 s- Qfile rename $ptp_file_name $tmp_file_name
/ X% V6 s( X( P( Hset ifile [open $tmp_file_name r]
7 T, h" q& N% g( K' l% C- ~set ofile [open $ptp_file_name w]
* l9 z5 g! ? u8 G7 p# jglobal mom_machine_time ! [2 l( Q& X" n; N" M" X6 P
puts $ofile "(CYCLE TIME = [format "%.2f" $mom_machine_time] MIN.)"
2 w$ |/ \' f7 f( K, Q" ]set buf "" while { [gets $ifile buf] > 0 } { puts $ofile $buf } # E- d7 S7 H) V% ^* H. @
close $ifile
& M2 T# C8 @5 g' Q! Zclose $ofile
; }- V4 X3 h0 i6 B0 j4 j6 P: G4 RMOM_remove_file $tmp_file_name ! B% J v, E0 X% m* K8 l1 s$ r9 n, q5 Z
MOM_open_output_file $ptp_file_name / C: U9 Y8 J, b' q, \; M( f
0 s* b; E1 d) o T/ |/ Z |
|