Beispiel #1
0
def check_and_upload(url, filename, sha1):
    if not os.path.exists(filename) or utils.sha1(filename) != sha1:
        if not utils.copy_file_from_url(url, filename, sha1):
            return False

    return True
Beispiel #2
0
def check_and_upload(url, filename, sha1):
    if not os.path.exists(filename) or utils.sha1(filename) != sha1:
        if not utils.copy_file_from_url(url, filename, sha1):
            return False

    return True
Beispiel #3
0
def write_sha1(out_dir, in_file):
    sha1 = utils.sha1(in_file)
    utils.write_sha1(sha1, out_dir + "sha1.sum")
Beispiel #4
0
def write_sha1(out_dir, in_file):
    sha1 = utils.sha1(in_file)
    utils.write_sha1(sha1, out_dir + "sha1.sum")