Skip to content

Commit

Permalink
Adds YGM version to ygm::comm:welcome()
Browse files Browse the repository at this point in the history
  • Loading branch information
steiltre committed Oct 4, 2024
1 parent 8e6eb30 commit 15af5ce
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions include/ygm/detail/comm.ipp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
#include <ygm/detail/lambda_compliance.hpp>
#include <ygm/detail/meta/functional.hpp>
#include <ygm/detail/ygm_cereal_archive.hpp>
#include <ygm/version.hpp>

namespace ygm {

Expand Down Expand Up @@ -90,6 +91,7 @@ inline void comm::welcome(std::ostream &os) {
auto end = version_string.find_first_of(delimiters);

sstr << "MPI_IMPLEMENTATION = " << version_string.substr(0, end) << "\n";
sstr << "YGM_VERSION = " << ygm_version << "\n";

config.print(sstr);

Expand Down
10 changes: 10 additions & 0 deletions include/ygm/version.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
// Copyright 2019-2021 Lawrence Livermore National Security, LLC and other YGM
// Project Developers. See the top-level COPYRIGHT file for details.
//
// SPDX-License-Identifier: MIT

#include <string>

namespace ygm {
static const std::string ygm_version("v0.7-dev");
}

0 comments on commit 15af5ce

Please sign in to comment.