0

i want to send commands into a screen with .sh script. Start a CSGO server with: screen -S cs ./srcds_run -game csgo -usercon How can i send a command to the csgo server like: sv_cheats 1

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62

1 Answers1

0

From the screen manpage:

-X Send the specified command to a running screen session.

At https://unix.stackexchange.com/questions/13953/sending-text-input-to-a-detached-screen you find a similar question.

So for your specific problem the solution would be:

screen -S cs -X stuff "sv_scheats 1"
Community
  • 1
  • 1
dingensundso
  • 176
  • 4