Skip to content

Instantly share code, notes, and snippets.

@PrivacyPolicy
PrivacyPolicy / ResearchSetup.py
Last active July 11, 2017 19:11
Script to setup environment for working with research project training on Florida Poly's machines
# Download executable file from the internet and run it
def run_online_exe(url, dir, exe, run=True):
# "Sanitize" input
if exe[-4:] != '.exe':
exe += '.exe'
# Download file as zip
from urllib.request import urlretrieve
zip_file_dir = exe.split('/')[-1][:-4] + '.zip'
urlretrieve(url, zip_file_dir)
# Unzip file