- 在本地安装、配置、创建公钥并上传公钥(具体过程见另一篇博客)
- 通过网页在Github中新建一个Repository仓库,并获取其clone地址,如
https://github.com/xxx/xxx.git
- 新建qt工程,在版本控制中选择Git
- 进入工程目录
$ git init #ls -al 可见.git文件
$ git remote add origin https://github.com/xxx/xxx.git
$ git push -u orgin master #完成第一次推送
即可在qt中使用git工具了,使用时先Local Commit再Remote Push。其他主机可以直接使用git clone获取到源码,然后直接使用qt git即可。