Gclone 一个 Rclone 的魔改版本支持分享转存突破750G限制

介绍

Gclone是一个基于Rclone的魔改版本,功能与原版Rclone相同,但增加了两个实用功能;

  • 支持服务端直接转存他人分享的文件及文件夹
  • 支持突破Google Drive单账号每日750G限制,基于GoogleService Account服务
  • GitHub项目:https://github.com/donwa/gclone

Gclone

bash <(wget -qO- https://git.io/gclone.sh)

为了以后使用方便,直接将gclone改名rclone

cp /usr/bin/gclone /usr/bin/rclone

Gclone 新增操作命令

rclone copy 配置名字:{文件ID} 配置名字:网盘路径 --drive-server-side-across-configs

说明:{文件ID}可以是分享的单独文件也可以是文件夹
分享链接一般是这样的:https://drive.google.com/drive/folders/XXXXXX
最后面的一串字符XXXXXX既是分享ID
关于突破750G需要使用GoogleService Account服务,过程有些复杂,如果没需求就不用弄了;
需要的话可以自行Google教程Service Account100个文件最好保存到本地,方便以后使用;

Fclone

GitHub中选择需要的Fclone版本,然后在本地解压得到名为fclone的文件
然后将得到的fclone文件上传至服务器/usr/bin目录下
赋予Fclone权限

chmod +x /usr/bin/fclone

使用时命令改为fclone即可,或者改名为rclone

cp /usr/bin/fclone /usr/bin/rclone

安装过程

如果有Service Account100个文件的话,就先建立以下目录,然后上传文件到accounts目录下

mkdir /root/AutoRclone
mkdir /root/AutoRclone/accounts

如果没有Service Account就略过,直接开始下面的安装即可;
脚本刚才已经下载过了,现在直接输入rclone config开始安装

n) New remote
s) Set configuration password
q) Quit config
n/s/q> n   # 输入n回车,新建配置
name> GD   # 新建配置的名称,自行设定
Type of storage to configure.
Enter a string value. Press Enter for the default ("").
Choose a number from below, or type in your own value
 1 / 1Fichier
   \ "fichier"
 2 / Alias for an existing remote
   \ "alias"
 3 / Amazon Drive
   \ "amazon cloud drive"
 4 / Amazon S3 Compliant Storage Provider (AWS, Alibaba, Ceph, Digital Ocean, Dreamhost, IBM COS, Minio, etc)
   \ "s3"
 5 / Backblaze B2
   \ "b2"
 6 / Box
   \ "box"
 7 / Cache a remote
   \ "cache"
 8 / Dropbox
   \ "dropbox"
 9 / Encrypt/Decrypt a remote
   \ "crypt"
10 / FTP Connection
   \ "ftp"
11 / Google Cloud Storage (this is not Google Drive)
   \ "google cloud storage"
12 / Google Drive
   \ "drive"
13 / Google Photos
   \ "google photos"
14 / Hubic
   \ "hubic"
15 / JottaCloud
   \ "jottacloud"
16 / Koofr
   \ "koofr"
17 / Local Disk
   \ "local"
18 / Mega
   \ "mega"
19 / Microsoft Azure Blob Storage
   \ "azureblob"
20 / Microsoft OneDrive
   \ "onedrive"
21 / OpenDrive
   \ "opendrive"
22 / Openstack Swift (Rackspace Cloud Files, Memset Memstore, OVH)
   \ "swift"
23 / Pcloud
   \ "pcloud"
24 / Put.io
   \ "putio"
25 / QingCloud Object Storage
   \ "qingstor"
26 / SSH/SFTP Connection
   \ "sftp"
27 / Union merges the contents of several remotes
   \ "union"
28 / Webdav
   \ "webdav"
29 / Yandex Disk
   \ "yandex"
30 / http Connection
   \ "http"
31 / premiumize.me
   \ "premiumizeme"
Storage> 12       # 选择需要挂载的网盘类型
** See help for drive backend at: https://rclone.org/drive/ **

Google Application Client Id
Setting your own is recommended.
See https://rclone.org/drive/#making-your-own-client-id for how to create your own.
If you leave this blank, it will use an internal key which is low performance.
Enter a string value. Press Enter for the default ("").
client_id>        # 默认直接回车,或者输入自己的OAuth ID
Google Application Client Secret
Setting your own is recommended.
Enter a string value. Press Enter for the default ("").
client_secret>    # 默认直接回车,或者输入自己的OAuth秘锁
Scope that rclone should use when requesting access from drive.
Enter a string value. Press Enter for the default ("").
Choose a number from below, or type in your own value
 1 / Full access all files, excluding Application Data Folder.
   \ "drive"
 2 / Read-only access to file metadata and file contents.
   \ "drive.readonly"
   / Access to files created by rclone only.
 3 | These are visible in the drive website.
   | File authorization is revoked when the user deauthorizes the app.
   \ "drive.file"
   / Allows read and write access to the Application Data folder.
 4 | This is not visible in the drive website.
   \ "drive.appfolder"
   / Allows read-only access to file metadata but
 5 | does not allow any access to read or download file content.
   \ "drive.metadata.readonly"
scope> 1 # 选择1然后回车
ID of the root folder
Leave blank normally.

Fill in to access "Computers" folders (see docs), or for rclone to use
a non root folder as its starting point.

Note that if this is blank, the first time rclone runs it will fill it
in with the ID of the root folder.

Enter a string value. Press Enter for the default ("").
root_folder_id>        # 直接回车
Service Account Credentials JSON file path 
Leave blank normally.
Needed only if you want use SA instead of interactive login.
Enter a string value. Press Enter for the default ("").
service_account_file> # 直接回车,如果使用Service Account就填写其中一个文件的绝对路径即可:/root/AutoRclone/accounts/0a5af037763bdab70e3a7094d02ec4bd37f8db94.json
Service Account Credentials JSON file path .

Enter a string value. Press Enter for the default ("").
service_account_file_path> 直接回车,如果使用Service Account就填写这个路径:/root/AutoRclone/accounts/
Edit advanced config? (y/n)
y) Yes
n) No (default)
y/n> n                    # 选择n 不使用高级配置
Remote config
Configure this as a team drive?
y) Yes
n) No (default)
y/n> y                     # 选择n不加载团队盘,选择y加载团队盘
Fetching team drive list...
Choose a number from below, or type in your own value
 1 / 网盘01
   \ "0AFZFXMn1uKs2Uk9PVA"
 2 / 网盘05
   \ "0AI3nH3Vf8NWIUk9PVA"
 3 / 网盘02
   \ "0ADYACmKjlU3JUk9PVA"
Enter a Team Drive ID> # 选择你的团队盘编号
y) Yes this is OK
e) Edit this remote
d) Delete this remote
y/e/d> y       # 选择y回车
Current remotes:

Name                 Type
====                 ====
网盘01             drive

e) Edit existing remote
n) New remote
d) Delete remote
r) Rename remote
c) Copy remote
s) Set configuration password
q) Quit config
e/n/d/r/c/s/q> q   # 输入q回车,保存配置退出

版权声明:东成西就 发表于 2020-10-20 18:20:40。
转载请注明:Gclone 一个 Rclone 的魔改版本支持分享转存突破750G限制 | 云知道

暂无评论

暂无评论...