Skip to content

Instantly share code, notes, and snippets.

@adamshamsudeen
Last active June 23, 2020 10:01
Show Gist options
  • Save adamshamsudeen/c8ef1481d52b5a29c98dd557182a11be to your computer and use it in GitHub Desktop.
Save adamshamsudeen/c8ef1481d52b5a29c98dd557182a11be to your computer and use it in GitHub Desktop.
import pyautogui
import time
#enable accssibilty permssion to terminal
#first get the position to click.
# pos = pyautogui.position()
# print(pos)
# x=1388, y=667
while True:
pyautogui.moveTo(1372, 670) # move mouse to the window
pyautogui.dragTo(1372, 670, button = 'left') # focus the window
pyautogui.click(1372, 670, button = 'left') # simulate left click
print("click")
time.sleep(4)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment