diff --git a/src/system_tray.cpp b/src/system_tray.cpp index 57175bd0..4b10acff 100644 --- a/src/system_tray.cpp +++ b/src/system_tray.cpp @@ -49,9 +49,11 @@ namespace system_tray { // this isn't ideal as it briefly shows a command window // but start a command built into cmd, not an executable std::string cmd = R"(cmd /C "start )" + url + R"(")"; - #else // if unix + #elif defined(__linux__) || defined(linux) || defined(__linux) // set working dir to user home directory working_dir = boost::filesystem::path(std::getenv("HOME")); + std::string cmd = R"(xdg-open ")" + url + R"(")"; + #elif defined(__APPLE__) || defined(__MACH__) std::string cmd = R"(open ")" + url + R"(")"; #endif