Moving json from API to dedicated folder

This commit is contained in:
Alexandre Aubin 2017-03-08 09:21:43 -05:00
parent 0911ebb1e1
commit 80df6a6bcd
4 changed files with 3 additions and 3 deletions

2
.gitignore vendored
View file

@ -1 +1 @@
*.json data/*.json

View file

@ -48,7 +48,7 @@ def main():
print("Analyzing %s ..." % repo) print("Analyzing %s ..." % repo)
with open("./%s.json" % repo, "r") as f: with open("data/%s.json" % repo, "r") as f:
j = json.loads(f.read()) j = json.loads(f.read())
for issue in j: for issue in j:

0
data/.gitkeep Normal file
View file

View file

@ -14,5 +14,5 @@ for repo in repos:
issues = requests.get("https://api.github.com/repos/yunohost/%s/issues?per_page=100" % repo) issues = requests.get("https://api.github.com/repos/yunohost/%s/issues?per_page=100" % repo)
with open("./%s.json" % repo, "w") as f: with open("data/%s.json" % repo, "w") as f:
f.write(issues.text) f.write(issues.text)