Skip to content

Commit bc7d139

Browse files
committed
Fix templates_url
1 parent 64702e4 commit bc7d139

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

jamstack/jamdo/jamdo.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
import requests
66
from tqdm import tqdm
77

8+
templates_url = ("https://api.github.com/repos/jamstackpy/"
9+
"jamstack-templates/git/trees/main?recursive=1")
10+
811

912
def get_raw_url(file_path, url):
1013
tmp_url = url.replace(
@@ -16,11 +19,9 @@ def get_raw_url(file_path, url):
1619

1720

1821
def get_download_links(template):
19-
api = requests.get(
20-
"https://api.github.com/repos/jamstackpy/\
21-
jamstack-templates/git/trees/main?recursive=1").text
22+
api = requests.get(templates_url).text
23+
print(templates_url)
2224
files = json.loads(api)
23-
2425
output = []
2526
location = dict()
2627
for (k, i) in enumerate(files['tree']):

0 commit comments

Comments
 (0)