TABLE OF CONTENTS


::pwtk::rerunCP

SYNOPSIS

proc ::pwtk::rerunCP {args} {

USAGE

rerunCP [options] input ?output?

DESCRIPTION

Re-run (restart) the cp.x calculation. Prior to running, this routine will set the restart_mode='restart' but only if restart_mode is undefined or 'from_scratch'. The output-file will be treated in append mode, whereas the rest is the same as for the ::pwtk::runCP routine.

OPTIONS

ARGUMENTS

SOURCE

    input_pushpop {
        set restart_mode [::pwtk::input::namelistGetVarValue CONTROL restart_mode trim]
        if { $restart_mode == "" || $restart_mode == "from_scratch" } {         
            CONTROL { 
                restart_mode = 'restart' 
            }
        }
        
        # remove ignored options from $args
        set ignored_options {
            {outdir_clean  "ignored option"}
        }
        array set opt [::cmdline::getKnownOptions args $ignored_options]
        
        if { $opt(outdir_clean) } {
            ::pwtk::warning "ignoring the -outdir_clean option, which disables the proper restart"
        }
        
        eval {runCP -append} $args
    }
}