diff --git a/DDG4/src/Geant4UIManager.cpp b/DDG4/src/Geant4UIManager.cpp index 3d6757a4d9b74e4c5b6f7df1f577a21a11bcfe28..37ebc5df82509b624f52bfa40262ac82fa1d2b01 100644 --- a/DDG4/src/Geant4UIManager.cpp +++ b/DDG4/src/Geant4UIManager.cpp @@ -152,14 +152,8 @@ void Geant4UIManager::start() { context()->kernel().runManager().BeamOn(numEvent); } catch (DD4hep_End_Of_File& e) { printout(INFO,"Geant4UIManager","++ End of file reached, ending run..."); + context()->kernel().runManager().RunTermination(); } - // Execute the chained command statements - for(const auto& c : m_postRunCommands) { - printout(INFO,"Geant4UIManager","++ Executing Command statement:%s",c.c_str()); - mgr->ApplyCommand(c.c_str()); - executed_statements = true; - } - context()->kernel().runManager().RunTermination(); } /// Stop and release resources diff --git a/examples/CLICSiD/scripts/CLIC_G4Gun.py b/examples/CLICSiD/scripts/CLIC_G4Gun.py index e0f49f1be15429e9189da05bd2b94f908eed7089..6964c417406eadba0c55cd053ea7e187c76a2a6e 100644 --- a/examples/CLICSiD/scripts/CLIC_G4Gun.py +++ b/examples/CLICSiD/scripts/CLIC_G4Gun.py @@ -40,7 +40,6 @@ def run(): merger.enableUI() kernel.generatorAction().adopt(merger) - # And handle the simulation particles. part = DDG4.GeneratorAction(kernel,"Geant4ParticleHandler/ParticleHandler") kernel.generatorAction().adopt(part) @@ -52,11 +51,6 @@ def run(): user.enableUI() part.adopt(user) # - # Setup the GDML writer action - writer = DDG4.Action(kernel,'Geant4GDMLWriteAction/Writer') - writer.enableUI() - kernel.registerGlobalAction(writer) - sid.setupDetectors() sid.setupPhysics('QGSP_BERT') sid.test_config()