evernote-backup init-db --backend china -t <你的开发者令牌DeveloperToken>
示例:
evernote-backup init-db --backend china -t S=T3I:U=wNnMC:E=Gi9fzR0k8lr:C=H8d2itP14G1:P=YW9S:A=eF0BPwgRiDM:V=q:H=OZDPLnUVQ56R3MSHObdJQZtVrTCn53JS
完整示例:
$ evernote-backup init-db --force --backend china -t S=T3I:U=wNnMC:E=Gi9fzR0k8lr:C=H8d2itP14G1:P=YW9S:A=eF0BPwgRiDM:V=q:H=OZDPLnUVQ56R3MSHObdJQZtVrTCn53JS
Authorizing auth token, china backend...
Successfully authenticated as YOUR_USER_NAME!
Current login will expire at 2024-05-13 15:43:53.
Initializing database en_backup.db...
Reading database en_backup.db...
Successfully initialized database for YOUR_USER_NAME!
4.1.2 Evernote (国际版)
如果是国际版本身是可以导出为 *.enex 格式文件的,但也希望本地备份的可以执行
evernote-backup init-db
国际版如果采用苹果或者Google账号授权登录的,则需要使用以下命令
evernote-backup init-db --oauth
输入命名后,根据提示依次输入用户名或邮箱(Username or Email)、密码(Password:)、如果是国际版的并采用账号授权的则输入一次性代码(Enter one-time code)。
完整示例:
$ evernote-backup init-db
Username or Email: user@example.com
Password:
Logging in to Evernote...
Enter one-time code: 120917
Authorizing auth token, evernote backend...
Successfully authenticated as YOUR_USER_NAME!
Current login will expire at 2022-03-10 10:22:00.
Initializing database en_backup.db...
Reading database en_backup.db...
Successfully initialized database for YOUR_USER_NAME!
evernote-backup reauth --token S=T3I:U=wNnMC:E=Gi9fzR0k8lr:C=H8d2itP14G1:P=YW9S:A=eF0BPwgRiDM:V=q:H=OZDPLnUVQ56R3MSHObdJQZtVrTCn53JS
Reading database en_backup.db...
Authorizing auth token, china backend...
Successfully authenticated as YOUR_USER_NAME!
Current login will expire at 2024-05-13 15:43:53.
Successfully refreshed auth token for YOUR_USER_NAME!
4.3 同步笔记数据
evernote-backup sync
当看到提示 Synchronization completed! 就代表同步成功了。
示例:
$ evernote-backup sync
Reading database en_backup.db...
Authorizing auth token, evernote backend...
Successfully authenticated as YOUR_USER_NAME!
Current login will expire at 2022-03-10 10:22:00.
Syncing latest changes...
[####################################] 6763/6763
566 notes to download...
[####################################] 566/566
Updated or added notebooks: 23
Updated or added notes: 566
Expunged notebooks: 0
Expunged notes: 0
Synchronization completed!
该方法支持断点续传,即可以随时中断再次运行本命令后可以从上次断开处继续下载数据,如报错
Aborting, please wait... Rate limit reached. Restart program in 14:30.
则需要等待对应的时间后再次执行命令
当看到 Synchronization completed! ,本次同步就完成了:
$ evernote-backup sync
Reading database en_backup.db...
Authorizing auth token, china backend...
Successfully authenticated as YOUR_USER_NAME!
Current login will expire at 2024-05-13 15:43:53.
Syncing user notebooks...
User notebooks are up to date, nothing to sync!
Syncing linked notebooks...
113 note(s) to download...
Requesting access to 1 linked notebook(s)...
Downloading 113 note(s)...
[####################################] 113/113
Updated or added notebooks: 0
Updated or added notes: 113
Expunged notebooks: 0
Expunged linked notebooks: 0
Expunged notes: 0
Synchronization completed!