Skip to content

Commit 4564497

Browse files
author
lucasgit13
committed
clean some code
1 parent 2eaf689 commit 4564497

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

Get-Dir-Github-Repo/get.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def Get(url):
121121
try:
122122
sp = url.split("/")
123123
if len(sp) > 5:
124-
for token in range(0, 7):
124+
for _ in range(0, 7):
125125
sp.pop(0)
126126
path = "/".join(sp)
127127

@@ -262,23 +262,23 @@ def fetch(obj):
262262

263263
if include_list:
264264
print("Searching for matches...")
265-
(new_obj, matches) = include(obj, include_list)
265+
(obj_, matches) = include(obj, include_list)
266266

267267
if matches != 0:
268-
obj = new_obj
269-
del new_obj
268+
obj = obj_
269+
del obj_
270270
print(f"{matches} matches found to include")
271271
else:
272272
sys.exit(f"no matches for {include_list}")
273273

274274
if exclude_list:
275-
m = search_pattern(obj, exclude_list)
276-
if m:
277-
obj_ = exclude(obj, exclude_list, m)
275+
matches = search_pattern(obj, exclude_list)
276+
if matches:
277+
obj_ = exclude(obj, exclude_list, matches)
278278
obj = obj_
279279
del obj_
280280
else:
281-
print(f"{m} matches found to ignore")
281+
print(f"{matches} matches found to ignore")
282282

283283
print(f"\nClonning into {directory}...")
284284

0 commit comments

Comments
 (0)