[root@yoyo git_code]$ git add * #*是提交当前文件夹下全部的,也可以指定提交一个文件如:test.py
[root@yoyo git_code]$ git commit -m "add test.py"
[root@yoyo git_code]$ git remote add origin
http://52.221.x.x:8100/root/yoyo.git
[root@yoyo git_code]$ git push -u origin master #push的时候,会让你输入账号和密码,这里的用户名和密码就是gitlab上注册的用户了