summaryrefslogtreecommitdiffstats
path: root/scripts/python/orgclone.py
blob: 139d7c556aafbc8ec05675c920333b76b9c7b807 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/local/bin/python3.8
import requests
from git import Repo

organization = 'LibertaCasa'
URL = 'https://git.com.de/api/v1/orgs/' + organization + '/repos'

response = requests.get(
        URL,
        headers = {'accept': 'application/json'},
        )
data = response.json()
repo = []
for repos in data:
    reponame = repos['name']
    repourl = repos['ssh_url']
    print(reponame + ' ' + repourl)
    Repo.clone_from(repourl, reponame)