add gen sizeinfo sh

This commit is contained in:
Julian Freeman
2026-02-26 19:03:25 -04:00
parent 85be19a06e
commit c9c8576401
2 changed files with 23 additions and 2 deletions

View File

@@ -4,13 +4,13 @@ setlocal
if "%~1"=="" goto usage
if "%~2"=="" goto usage
set PATH=%~1
set TARGET_PATH=%~1
set FILE_NAME=%~2
if not exist "man_files" mkdir "man_files"
echo Running rclone lsf ...
rclone lsf -R --format "sp" --separator "|" --local-encoding "None" --exclude-from exclude-list.txt "%PATH%" > "man_files\%FILE_NAME%"
rclone lsf -R --format "sp" --separator "|" --local-encoding "None" --exclude-from exclude-list.txt "%TARGET_PATH%" > "man_files\%FILE_NAME%"
if %ERRORLEVEL% equ 0 (
echo Success: File saved to man_files\%FILE_NAME%

21
gen_sizeinfo.sh Normal file
View File

@@ -0,0 +1,21 @@
#!/bin/bash
if [ -z "$1" ] || [ -z "$2" ]; then
echo "Usage: $0 <path> <file_name>"
echo "Example: $0 mydrive:backup|/path/to/dir manifest.txt"
exit 1
fi
TARGET_PATH="$1"
FILE_NAME="$2"
mkdir -p "man_files"
echo "Running ./rclone lsf ..."
./rclone lsf -R --format "sp" --separator "|" --local-encoding "None" --exclude-from "exclude-list.txt" "$TARGET_PATH" > "man_files/$FILE_NAME"
if [ $? -eq 0 ]; then
echo "Success: Saved to "man_files/$FILE_NAME""
else
echo "Error: rclone failed"
fi