diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..66fb822 --- /dev/null +++ b/.gitignore @@ -0,0 +1,69 @@ +*.py[cod] + +# C extensions +*.so + +# Packages +*.egg +*.egg-info +dist +build +eggs +parts +bin +var +sdist +develop-eggs +.installed.cfg +lib +lib64 +MANIFEST + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# pyenv +.python-version + +# Django stuff: +*.log +local_settings.py +db.sqlite3 + +# Flask stuff: +instance/ +.webassets-cache + +# Installer logs +pip-log.txt + +# Unit test / coverage reports +.coverage +.tox +nosetests.xml + +# Translations +*.mo + +# Mr Developer +.mr.developer.cfg +.project +.pydevproject + +env +env3 +__pycache__ +venv + +.cache +docs/_build +.idea/ + +.flask_todo + diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 0000000..fa1b462 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "python.pythonPath": ".venv\\Scripts\\python.exe" +} \ No newline at end of file diff --git a/main.py b/main.py index f2f1db2..7076b37 100644 --- a/main.py +++ b/main.py @@ -10,11 +10,10 @@ username = sys.argv[1] # TODO: - # - # 1. Retrieve a list of "events" associated with the given user name - # 2. Print out the time stamp associated with the first event in that list. + response = requests.get(f"https://api.github.com/users/{username}/events") + events = json.loads(response.content) + # print(events) + print(events[0]["created_at"]) - print("COMPLETE THE TODOs") -