Search code examples
pythonlinuxgoogle-colaboratoryspeed-test

How to automate a command input in Colab


As you can see in this image Everytime i have to agree to the speedtest terms of Ookla by typing 'Y'. Is there any way to automate this input. (in the same cell). Such that i won't have to type 'y' personally there

I tried finding a solution on Google. But google doesn't seem to understand my query


Solution

  • You can use the pipe | to redirect stdout to stdin.

    ! echo YES | speedtest