本例介绍简单实用GitLab,安装请参照【Git】 GitLab服务器社区版安装与配置
1、用户和组的管理
a、创建组,在首页点击Create a group
b、创建用户,在首页点击Add people
2、创建项目,在首页点击Create a project
3、项目开发,管理员在后台邀请test用户开发test01项目。
使用test用户登录,显示如下:
使用git命令,克隆项目进行开发
Command line instructions Git global setup
git config --global user.name "Administrator"
git config --global user.email "admin@example.com" Create a new repository
git clone http://git.xxx.com/root/test01.git
cd test01
touch README.md
git add README.md
git commit -m "add README"
git push -u origin master Existing folder
cd existing_folder
git init
git remote add origin http://git.xxx.com/root/test01.git
git add .
git commit -m "Initial commit"
git push -u origin master Existing Git repository
cd existing_repo
git remote rename origin old-origin
git remote add origin http://git.xxx.com/root/test01.git
git push -u origin --all
git push -u origin --tags