first
This commit is contained in:
parent
359e111cb0
commit
76ae9d571d
16
clone_all.py
Normal file
16
clone_all.py
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
import requests # must install this module with pip or package manager
|
||||||
|
from git import Repo # must install gitpython module
|
||||||
|
|
||||||
|
def main():
|
||||||
|
# Perform request
|
||||||
|
userid = "fossilfranv"
|
||||||
|
passw = "mUlUmuqi#$%"
|
||||||
|
token = "25135836368a30b70cbaa4aa56e8a40f04bf6030"
|
||||||
|
r = requests.get("https://git.franv.site/api/v1/repos/search?token=" + token)
|
||||||
|
|
||||||
|
# Loop through each repository returned, cloning it
|
||||||
|
for repository in r.json()["data"]:
|
||||||
|
Repo.clone_from(repository["clone_url"], "repos/" + repository["full_name"])
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
main()
|
||||||
Loading…
Reference in New Issue
Block a user