Skip to content

Commit

Permalink
Save KEY4HEP_STACK env var to metadata (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
vvolkl authored Mar 15, 2022
1 parent 49c371c commit 061f6b5
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions k4FWCore/components/PodioOutput.cpp
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#include <cstdlib>

#include "PodioOutput.h"
#include "k4FWCore/PodioDataSvc.h"
#include "TFile.h"
Expand Down Expand Up @@ -174,6 +176,12 @@ StatusCode PodioOutput::finalize() {
}
//// finalize trees and file //////////////////////////////
m_file->cd();

if(const char* env_key4hep_stack = std::getenv("KEY4HEP_STACK")) {
std::string s_env_key4hep_stack = env_key4hep_stack;
m_metadatatree->Branch("key4hepStack", &s_env_key4hep_stack);
}

m_metadatatree->Branch("gaudiConfigOptions", &config_data);
m_metadatatree->Branch("CollectionIDs", m_podioDataSvc->getCollectionIDs());

Expand Down

0 comments on commit 061f6b5

Please sign in to comment.