Sfoglia il codice sorgente

Further git test code

tags/3.1_alpha
Manuel83 8 anni fa
parent
commit
f07a2bdd7a
1 ha cambiato i file con 13 aggiunte e 2 eliminazioni
  1. +13
    -2
      gittest.py

+ 13
- 2
gittest.py Vedi File

@@ -1,7 +1,18 @@
import requests
from git import Repo, Git

repo = Repo('./')
print repo
for remote in repo.remotes:
print remote
remote.fetch()ls

remote.fetch()

url = 'https://api.github.com/repos/manuel83/craftbeerpi3/releases'
response = requests.get(url)

result = []

for r in response.json():
result.append({"tag_name": r.get("tag_name"), "timestamp": r.get("created_at")})

print result

Loading…
Annulla
Salva