Skip to main content
100%

Gist 53c785af36b91d5ad12983f35f1a3020

✓ Published0🌍 Public
Aadamscott
Last edited Jun 16, 2016
Created on Jun 16, 2016

This example demonstrates a file-splitting utility that pauses after creating each chunk, waiting for the split file to be manually deleted before proceeding to the next one. The script reads data from standard input, writes it to sequentially named files (e.g., backup/filename.aa, .ab, …), and generates a SHA256 checksum for each part. It uses Python’s `sys.stdin.buffer`, `subprocess.getoutput` for hashing, and `os.path.isfile` to monitor file deletion. The suffix logic implements a base-26 letter system with `math.floor` for indexing. The process repeats until input is exhausted.

AI-generated description

Similar vizzes