背景:
本地电脑A可以链接gitlab,远程的服务器B不能连接gitlab,需要在B上开发,和运行程序。
办法:
使用vscode rsync 将代码从本地A上同步到B,B上开发好后,在A上将代码同步到本地,然后提交到gitlab.
在.vscode目录下的setting.json中加入如下字段
“sync-rsync.exclude”: [
“.git”,
“.vscode”,
“.ccls-cache”,
“bin/”,
“build/”,
“lib/”,
“log/”,
“.gitignore”,
“eco.srctrl*”
],
// “sync-rsync.shell”: “ssh -p port”,
“sync-rsync.remote”: “xxxxx/workspace/”,
“sync-rsync.local”: “xxxxx/workspace”,
“sync-rsync.onSaveIndividual”: true,
“sync-rsync.executableShell”: “/bin/bash”,



