Created
March 22, 2024 20:29
-
-
Save Kambaa/0298c3e2c48bd8da40534e0d4e73b4a1 to your computer and use it in GitHub Desktop.
Linux auto enter text example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
string="EXAMPLE_TEXT..." | |
delay=0.05 # Delay between character inputs in seconds | |
sleep "0.5" # initial wait, without this, some of the chars in the beginning is missing | |
for char in ${string}; do | |
xdotool type "${char}" && sleep "${delay}" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment