Format with black
This commit is contained in:
parent
2580c3e874
commit
25491e0d6d
14
netrun.py
14
netrun.py
|
@ -6,13 +6,15 @@ url = sys.argv[1]
|
||||||
|
|
||||||
content = requests.get(url).content
|
content = requests.get(url).content
|
||||||
|
|
||||||
subprocess.run(['less'], input=content)
|
subprocess.run(["less"], input=content)
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
response = input('Do you want to run this script? [y/n] ').lower().strip()[0]
|
response = (
|
||||||
if response == 'y':
|
input("Do you want to run this script? [y/n] ").lower().strip()[0]
|
||||||
subprocess.run(['bash'], input=content)
|
)
|
||||||
|
if response == "y":
|
||||||
|
subprocess.run(["bash"], input=content)
|
||||||
break
|
break
|
||||||
elif response == 'n':
|
elif response == "n":
|
||||||
print('Script not run.')
|
print("Script not run.")
|
||||||
break
|
break
|
||||||
|
|
Loading…
Reference in New Issue
Block a user