Skip to content

Commit

Permalink
update gha
Browse files Browse the repository at this point in the history
  • Loading branch information
jacopocarlini committed May 10, 2024
1 parent 4143985 commit a08d830
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions .github/workflows/update_gha.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,16 @@
import requests
import json
import requests


url = 'https://github.com/pagopa/template-java-spring-microservice/tree/main/.github/workflows'
url = 'https://api.github.com/repos/pagopa/template-java-spring-microservice/contents/.github/workflows'
url_raw = 'https://raw.githubusercontent.com/pagopa/template-java-spring-microservice/main/'

response = requests.get(url)

for item in json.loads(response.text)["payload"]["tree"]["items"]:
for item in json.loads(response.text):
path = item["path"]
name = item["name"]
print(name)
response = requests.get(url_raw+path)
response = requests.get(url_raw + path)
fo = open(name, "w")
fo.write(response.text)
fo.close()


0 comments on commit a08d830

Please sign in to comment.