Last active
February 24, 2021 16:06
-
-
Save yuyosy/6bec47e05412246fb09867cb33fc4ed6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import base64 | |
import os | |
import sys | |
def basestr_to_file(s, outfile_path): | |
with open(outfile_path, "wb") as f: | |
f.write(base64.b85decode(s)) | |
if __name__ == "__main__": | |
args = sys.argv | |
path = input('Path> ') if len(args) == 1 else args[1] | |
with open(path, mode='rb') as f: | |
data = f.read() | |
basestr_to_file(data, os.path.join(os.path.dirname(path), 'get.zip')) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment