@@ -911,23 +911,22 @@ function (Message $message, string $command, array $message_filtered): PromiseIn
911911 OSFunctions::execInBackground ('killall index.js ' );
912912 return $ this ->civ13 ->reply ($ message , '**TypeSpess Civ13** test server down. ' );
913913 }, ['Owner ' , 'Chief Technical Officer ' ]);
914- if (isset ($ this ->civ13 ->folders ['ss14_basedir ' ]))
915- $ this ->messageHandler ->offsetSet ('ss14 ' ,
916- function (Message $ message , string $ command , array $ message_filtered ): PromiseInterface
917- {
918- if (! $ state = trim (substr ($ message_filtered ['message_content_lower ' ], strlen ($ command )))) return $ this ->civ13 ->reply ($ message , 'Wrong format. Please try `ss14 on` or `ss14 off`. ' );
919- if (! in_array ($ state , ['on ' , 'off ' ])) return $ this ->civ13 ->reply ($ message , 'Wrong format. Please try `ss14 on` or `ss14 off`. ' );
920- if ($ state === 'on ' ) {
921- OSFunctions::execInBackground ("cd {$ this ->civ13 ->folders ['ss14_basedir ' ]}" );
922- OSFunctions::execInBackground ('git pull ' );
923- OSFunctions::execInBackground ("dotnet run --project Content.Packaging server --hybrid-acz --platform linux-x64 " );
924- OSFunctions::execInBackground ("dotnet run --project Content.Server --config-file server_config.toml " );
925- return $ this ->civ13 ->reply ($ message , 'Put **Civ14** test server on: `TODO: URL` ' );
926- }
927- //OSFunctions::execInBackground('killall index.js');
928- //return $this->civ13->reply($message, '**Civ14** test server down.');
929- return $ this ->civ13 ->reply ($ message , 'This feature is not yet implemented. ' );
930- }, ['Owner ' , 'Chief Technical Officer ' ]);
914+ $ this ->messageHandler ->offsetSet ('ss14 ' ,
915+ function (Message $ message , string $ command , array $ message_filtered ): PromiseInterface
916+ {
917+ if (! $ state = trim (substr ($ message_filtered ['message_content_lower ' ], strlen ($ command )))) return $ this ->civ13 ->reply ($ message , 'Wrong format. Please try `ss14 on` or `ss14 off`. ' );
918+ if (! in_array ($ state , ['on ' , 'off ' ])) return $ this ->civ13 ->reply ($ message , 'Wrong format. Please try `ss14 on` or `ss14 off`. ' );
919+ if ($ state === 'on ' ) {
920+ OSFunctions::execInBackground ("cd '/home/civ13/civ14' " );
921+ OSFunctions::execInBackground ('git pull ' );
922+ OSFunctions::execInBackground ("dotnet run --project Content.Packaging server --hybrid-acz --platform linux-x64 " );
923+ OSFunctions::execInBackground ("dotnet run --project Content.Server --config-file server_config.toml " );
924+ return $ this ->civ13 ->reply ($ message , 'Put **Civ14** test server on: `TODO: URL` ' );
925+ }
926+ //OSFunctions::execInBackground('killall index.js');
927+ //return $this->civ13->reply($message, '**Civ14** test server down.');
928+ return $ this ->civ13 ->reply ($ message , 'This feature is not yet implemented. ' );
929+ }, ['Owner ' , 'Chief Technical Officer ' ]);
931930
932931 $ this ->__generateServerMessageCommands ();
933932 }
0 commit comments