Skip to content

Instantly share code, notes, and snippets.

@leejongyoung
Last active September 8, 2022 11:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save leejongyoung/b522638e45c68015cb14e3703eef7915 to your computer and use it in GitHub Desktop.
Save leejongyoung/b522638e45c68015cb14e3703eef7915 to your computer and use it in GitHub Desktop.

채원이가 부탁한 특정 시간에 특정 URL이 열리는 파이썬 프로그램

실행전 터미널 필수 명령어

pip install schedule

zshrc 파일에 넣어야하 명령어 (맨 뒤에)

python ScheduleOpenBrowser.py &

시스템 환경설정 → 사용자 및 그룹 → 로그인 항목 → 플러스 버트 → 터미널.app 추가

import time
import schedule
import datetime
import webbrowser
excute_time = "08:55"
url = 'https://auth.worksmobile.com'
def open_browser():
webbrowser.open(url)
return
if __name__ == "__main__":
schedule.every().day.at(excute_time).do(open_browser)
while True:
schedule.run_pending()
time.sleep(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment