1#include "G4Svc/Goofy.h"
2#include "G4Svc/GoofyMessenger.h"
3#include "G4Svc/ProjectMessenger.h"
4#include "G4Svc/RandomCenterMessenger.h"
8#include "G4UImanager.hh"
9#include "G4UIterminal.hh"
25 for (
int i = 1; i < npar; i++ ) opts.push_back( pars[i] );
34 G4UImanager* UI = G4UImanager::GetUIpointer();
35 if ( !initmacro.empty() ) UI->ApplyCommand(
"/control/execute " + initmacro );
37 else if ( rm ==
Batch )
41 if ( runmacro.empty() )
43 std::cout <<
" Batch mode selected but no macro file "
44 <<
"to run; Aborting!!!!" << std::endl;
47 UI->ApplyCommand(
"/control/execute " + runmacro );
55 delete theRandomCenter;
64 <<
"***********************************************************************" << std::endl
65 <<
"***********************************************************************" << std::endl
66 <<
"** **" << std::endl
67 <<
"** GGGGG OOOOO OOOOO FFFFFFF Y Y **" << std::endl
68 <<
"** G G O O O O F Y Y **" << std::endl
69 <<
"** G O O O O F Y Y **" << std::endl
70 <<
"** G O O O O FFFFF YYY **" << std::endl
71 <<
"** G GGGG O O O O F Y **" << std::endl
72 <<
"** G G O O O O F Y **" << std::endl
73 <<
"** GGGGG OOOOO OOOOO F Y **" << std::endl
74 <<
"** **" << std::endl
75 <<
"** **" << std::endl
76 <<
"** The Geant4-based Object Oriented FollY **" << std::endl
77 <<
"** **" << std::endl
78 <<
"** Jan 10th, 2000 **" << std::endl
79 <<
"** **" << std::endl
80 <<
"***********************************************************************" << std::endl
81 <<
"***********************************************************************" << std::endl
86 char* greetings = getenv(
"GOOFY_GREETINGS" );
88 if ( greetings )
Shell(
"xv -wait 2 $GOOFY_GREETINGS" );
91void Goofy::SetJobOptions() {
93 std::vector<std::string>::const_iterator it;
95 it = find( opts.begin(), opts.end(),
"-b" );
96 if ( it != opts.end() ) rm =
Batch;
98 it = find( opts.begin(), opts.end(),
"-i" );
99 if ( it != opts.end() )
105 it = find( opts.begin(), opts.end(),
"-m" );
106 if ( it != opts.end() )
static int Shell(std::string s)