This file contains hidden or 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
@echo off | |
setlocal enabledelayedexpansion | |
chcp 65001 >nul | |
set "LONG_PATH_PREFIX=//?/" | |
:start | |
:: ======== CONFIGURATION ======== | |
:: Change your target folder, output directory and split size here! (Set split size smaller than 8192m if uploading to YODA). For your remote path if you wish to upload after compression, check with "ibridges list". |
This file contains hidden or 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 os | |
import time | |
import base64 | |
import subprocess | |
import sys | |
import re | |
from datetime import datetime | |
def run_cmd(cmd): | |
result = subprocess.run(cmd, shell=True, capture_output=True, text=True) |
This file contains hidden or 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
""" | |
This script monitors a folder for new files and compresses them periodically using tar and Zstandard (zstd). It supports: | |
- Incremental backups (only compresses newly added or modified files) | |
- High compression levels (with options for speed/multithread) | |
- File integrity verification via checksums | |
- Automatic logging of backup metadata | |
CONFIGURATION: | |
- watch_dir: Path to monitor for file files. | |
- output_dir: Where compressed output will be stored. |