From fff509e91f2105543dfd95a75055598d824f1cb0 Mon Sep 17 00:00:00 2001 From: Marcus Whybrow Date: Wed, 30 May 2012 18:21:47 +0100 Subject: [PATCH] Added a console command. Which resumes the created screen session for a server. If the logged in user executing the command is connected via SSH, then unless that user is the server user, this command will (currently) fail, do to the way screen works. --- msm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/msm b/msm index ac89ecd..e0c5bfc 100755 --- a/msm +++ b/msm @@ -1744,6 +1744,13 @@ main() { fi fi ;; + console) + if server_is_running $id; then + as_user ${server_user_name[$1]} "screen -r ${server_screen_name[$1]}" + else + echo "Server \"${server_name[$id]}\" is not running." + fi + ;; *) echo "Invalid command." ;;