Skip to content

Commit

Permalink
Fix launching of Editor not propagating arguments under Linux
Browse files Browse the repository at this point in the history
  • Loading branch information
aeris170 committed Sep 5, 2024
1 parent 21c0ff3 commit cd3e81c
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Launcher/GUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -420,9 +420,12 @@ void GUI::RenderProjectData(ProjectData& data) noexcept {
if constexpr (detect::is_windows_v) {
exe = "start Editor.exe";
} else if constexpr (detect::is_linux_v) {
exe = "./Editor &";
exe = "./Editor";
}
std::string command = std::string(exe).append(1, ' ').append(data.AbsolutePath).append(data.Name).append(Assets::ProjectExtension);
if constexpr (detect::is_linux_v) {
command = command.append(" &");
}
auto sys = std::system(command.c_str());
if (sys == -1) {
DOA_LOG_WARNING("[Launcher::GUI] A call to std::system returned -1.");
Expand Down

0 comments on commit cd3e81c

Please sign in to comment.