From a8045e0c8c70e246333050bb5897252d5388d926 Mon Sep 17 00:00:00 2001 From: Simon Fels Date: Tue, 9 May 2017 07:27:21 +0200 Subject: [PATCH] Print snap revision if running inside a snap --- src/anbox/cmds/system_info.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/anbox/cmds/system_info.cpp b/src/anbox/cmds/system_info.cpp index ef90366..ea53d3a 100644 --- a/src/anbox/cmds/system_info.cpp +++ b/src/anbox/cmds/system_info.cpp @@ -53,6 +53,12 @@ class SystemInformation { << anbox::build::print_version() << std::endl; + if (anbox::utils::is_env_set("SNAP_REVISION")) { + s << "snap-revision: " + << anbox::utils::get_env_value("SNAP_REVISION") + << std::endl; + } + s << "os:" << std::endl << " name: " << os_info_.name << std::endl << " version: " << os_info_.version << std::endl