IDEA 2018.3配置git,并上传项目到github
一、环境要求
1、计算机应当安装了git
2、拥有github帐号
二、在IDEA中配置本机中的git的安装路径,如下图
file --> other settings --> setting for new projects --> version control --> git(不同IDEA版本可能有所不同,本次使用IDEA 2018.3)
三、IDEA中配置github帐号(没有的话去官网注册一个),如图
file --> other settings --> setting for new projects --> version control --> github
这样就完成了git/github的配置,记得应用并保存配置
四、接下来开始上传项目到github上
1、创建项目的本地git库:VCS --> import into version control --> create git repository
选中项目,点击OK
2、点击工程,右键:Git --> add
3、再次选中工程右键:Git -->commit repository ,填写提交信息,将工程提交到本地库
4、再次选中工程右键:Git --> repository --> push, 然后设置github上对应的仓库的uri,点击push即可
至此,完成了提交项目到github上
PS:如果发现什么地方错误,请务必指出,谢谢