Skip to content

Instantly share code, notes, and snippets.

@david4958606
Created April 27, 2021 15:13
Show Gist options
  • Save david4958606/ebac7ecaa323b63d678b9c07bb29d5c6 to your computer and use it in GitHub Desktop.
Save david4958606/ebac7ecaa323b63d678b9c07bb29d5c6 to your computer and use it in GitHub Desktop.
Generate rclone command
#!/bin/bash
#自动 rclone 到指定网盘 upload 文件夹下同名目录
#用法:rclone.sh <source path> <net disk> <threads>
src=$1
src=${src%?}
file=`echo $src | awk -F "/" '{print $NF}'`
disk=$2
upload="$2:/upload/${file}"
threads=$3
echo "screen rclone copy '${src}' '${upload}' -P --transfers ${threads}"
screen rclone copy '${src}' '${upload}' -P --transfers ${threads}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment