使用方法
下载插件sftp
按住crtl+shift+p选择
编辑sftp.json
{
"name": "My Server",
"host": "XXXX,
"protocol": "sftp",
"port": 22,
"username": "XXX",
"password": "XXXXXX",
"remotePath": "/app/release/bjcredit_web_test/biz",
"syncOption": {
"delete": true
},
"watcher": {
"files": "dist/",
"autoUpload": false,
"autoDelete": false
}
}
tips
- remotePath 表示服务器文件提交路径
- watcher->files 表示你本地要提交至服务器的文件,前端打包文件至dist,提交dist文件夹至/app/release/bjcredit_web_test/biz下
- 此时服务器上的文件在此可见,最好刷新确认
4 最新打包的文件上右键可将本地提交至远程,也可拉取远程文件到本地