Skip to content

Commit

Permalink
Fixed config dir
Browse files Browse the repository at this point in the history
  • Loading branch information
es3n1n committed Aug 6, 2020
1 parent b4bf077 commit 0891ee8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions __main__.py
Expand Up @@ -2,16 +2,17 @@
import requests
import logging
import json
import pathlib


logging.basicConfig(level=logging.INFO)

config = {}
with open("./config.json", "r") as f:
with open(str(pathlib.Path(__file__).parent / "config.json"), "r") as f:
config = json.loads(f.read())


base_file_url = "https://raw.githubusercontent.com/{}}/{}/master/".format(config["owner"], config["repo"])
base_file_url = "https://raw.githubusercontent.com/{}/{}/master/".format(config["owner"], config["repo"])
tree = requests.get("https://api.github.com/repos/{}/{}/git/trees/master?recursive=1"
.format(config["owner"], config["repo"]))
tree = tree.json()["tree"]
Expand Down

0 comments on commit 0891ee8

Please sign in to comment.